Skip to content

Instantly share code, notes, and snippets.

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?

@jamiegs
jamiegs / BundleConfig.ps1
Created July 1, 2016 19:16 — forked from mefellows/BundleConfig.ps1
Sysprepped Windows AMI using Packer
$EC2SettingsFile="C:\\Program Files\\Amazon\\Ec2ConfigService\\Settings\\BundleConfig.xml"
$xml = [xml](get-content $EC2SettingsFile)
$xmlElement = $xml.get_DocumentElement()
foreach ($element in $xmlElement.Property)
{
if ($element.Name -eq "AutoSysprep")
{
$element.Value="Yes"
}
/* XmlToMD.csx
*
* Converts .Net generated XML comments into a markdown file.
* Forked from: https://gist.github.com/lontivero/593fc51f1208555112e0
*
* Usage: scriptcs xmltomd.csx -- [XML_INPUT_FILE] <[MD_OUTPUT_FILE]>
*
* The second argument is optional, and will default to the same path
* & file name prefix as the input file.
*/
@lontivero
lontivero / gist:593fc51f1208555112e0
Last active June 24, 2023 20:05
Generates Markdown from VS XML documentation file
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text.RegularExpressions;
using System.Xml;
using System.Xml.Linq;
namespace GithubWikiDoc
{
@johntyree
johntyree / getBlockLists.sh
Last active March 9, 2024 12:32
Make one large blocklist from the bluetack lists on iblocklist.com
#!/usr/bin/env sh
# Download lists, unpack and filter, write to stdout
curl -s https://www.iblocklist.com/lists.php \
| sed -n "s/.*value='\(http:.*=bt_.*\)'.*/\1/p" \
| xargs wget -O - \
| gunzip \
| egrep -v '^#'
@phillip-haydon
phillip-haydon / Blobbed.cs
Created February 28, 2012 23:35
NHibernate Custom User Type for serializing a property to JSON
[Serializable]
public class Blobbed<T> : IUserType where T : class
{
public new bool Equals(object x, object y)
{
if (x == null && y == null)
return true;
if (x == null || y == null)
return false;
@zaius
zaius / background.sh
Created January 16, 2011 23:29
How to redirect a running process output to a file and log out
ctrl-z
bg
touch /tmp/stdout
touch /tmp/stderr
gdb -p $!
# In GDB
p dup2(open("/tmp/stdout", 1), 1)
p dup2(open("/tmp/stderr", 1), 2)