Skip to content

Instantly share code, notes, and snippets.

View aabs's full-sized avatar

Andrew Matthews aabs

View GitHub Profile
@anotherjesse
anotherjesse / relay.app
Created March 23, 2010 22:42
tcp relay in erlang
{application, relay,
[{description, "relay"},
{vsn, "0.01"},
{modules, [
relay_app,
relay_listener,
relay_sup,
relay_worker
]},
{registered, []},
@kyle-ilantzis
kyle-ilantzis / open-w-atom.reg
Last active June 1, 2021 17:20
Adds 'Open in Atom' to context menu in Windows Explorer.
Windows Registry Editor Version 5.00
;
; Adds 'Open in Atom' to context menu (when you right click) in Windows Explorer.
;
; Based on https://github.com/Zren/atom-windows-context-menu. It didn't work
; https://github.com/Zren/atom-windows-context-menu/issues/1.
;
; Save this file to disk with a .reg extension. Replace C:\\Atom\\atom.exe with
; the path to the atom executable on your machine.
@alecthegeek
alecthegeek / go-install-tools
Last active September 3, 2015 18:18
Set up a "standard" go project workspace with support for 3rdparty modules, version control repo and a template main package
# Install all the Go tools and godep tool
# Location of gobin is based on installation by OS X Homebrew
sudo -u admin GOPATH=/tmp GOBIN=/usr/local/opt/go/bin go get -u golang.org/x/tools/cmd/...
sudo -u admin GOPATH=/tmp GOBIN=/usr/local/opt/go/bin go get -u github.com/tools/godep
@acolyer
acolyer / service-checklist.md
Last active July 10, 2024 05:13
Internet Scale Services Checklist

Internet Scale Services Checklist

A checklist for designing and developing internet scale services, inspired by James Hamilton's 2007 paper "On Desgining and Deploying Internet-Scale Services."

Basic tenets

  • Does the design expect failures to happen regularly and handle them gracefully?
  • Have we kept things as simple as possible?
@rcmachado
rcmachado / Makefile
Last active February 7, 2024 06:04
Add a help target to a Makefile that will allow all targets to be self documenting
.SILENT:
.PHONY: help
# Based on https://gist.github.com/prwhite/8168133#comment-1313022
## This help screen
help:
printf "Available targets\n\n"
awk '/^[a-zA-Z\-\_0-9]+:/ { \
helpMessage = match(lastLine, /^## (.*)/); \
@Pitometsu
Pitometsu / configuration.nix
Last active July 11, 2023 18:58
NixOS system config
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, ... }:
rec {
imports =
@linktohack
linktohack / zshrc.zsh
Last active August 23, 2023 14:44
ZSH
export EDITOR=vim
export ZSH="$HOME/.oh-my-zsh"
ZSH_THEME="nicoulaj"
plugins=(asdf aws docker direnv fasd fzf git helm history jq kubectl macos)
source $ZSH/oh-my-zsh.sh
export FZF_DEFAULT_OPTS="--bind ctrl-k:kill-line,ctrl-b:preview-page-up,ctrl-f:preview-page-down"
export _FASD_BACKENDS="native spotlight"
export PATH="$PATH:$HOME/Library/Android/sdk/platform-tools"
odoo:
image: odoo:9
ports:
- "8069:8069/tcp"
links:
- "db:db"
db:
image: postgres:9
environment:
- POSTGRES_USER=odoo
@Sup3rc4l1fr4g1l1571c3xp14l1d0c10u5
Sup3rc4l1fr4g1l1571c3xp14l1d0c10u5 / TopologicalSort.cs
Created June 18, 2016 15:15
Topological Sorting (Kahn's algorithm) implemented in C#
using System;
using System.Collections.Generic;
using System.Linq;
namespace TopologicalSort {
static class Program {
static void Main() {
//
// digraph G {
// "7" -> "11"
@rymdolle
rymdolle / _rebar3
Created November 4, 2016 21:23
rebar3 autocomplete for zsh
#compdef rebar3
#autoload
# rebar3 zsh completion
typeset -A opt_args
_rebar3() {
local rebar3_commands cmd cmds
if [[ "$CURRENT" -lt 2 ]]; then