I was at Amazon for about six and a half years, and now I've been at Google for that long. One thing that struck me immediately about the two companies -- an impression that has been reinforced almost daily -- is that Amazon does everything wrong, and Google does everything right. Sure, it's a sweeping generalization, but a surprisingly accurate one. It's pretty crazy. There are probably a hundred or even two hundred different ways you can compare the two companies, and Google is superior in all but three of them, if I recall
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name "base" | |
description "Baseline configuration for all systems." | |
run_list( | |
"recipe[ohai]", | |
"recipe[chef-client::delete_validation]", | |
"recipe[chef-client]", | |
"recipe[zsh]", | |
"recipe[git]", | |
"recipe[users]", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FILE SPACING: | |
# double space a file | |
sed G | |
# double space a file which already has blank lines in it. Output file | |
# should contain no more than one blank line between lines of text. | |
sed '/^$/d;G' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
urlencode() { | |
# urlencode <string> | |
old_lc_collate=$LC_COLLATE | |
LC_COLLATE=C | |
local length="${#1}" | |
for (( i = 0; i < length; i++ )); do | |
local c="${1:$i:1}" | |
case $c in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/qsh | |
EXIT_SUCCESS=0 | |
EXIT_FAILURE=1 | |
EXIT_ERROR=2 | |
USERNAME="" | |
PASSWORD="" | |
INSTALL="n" | |
CREATE="n" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# Git clone all my gists | |
import json | |
import urllib | |
from subprocess import call | |
from urllib import urlopen | |
import os | |
USER = os.environ['USER'] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "Installing nagios-plugin" | |
cd nagios-plugins* | |
./configure --with-openssl=/usr/bin --with-mysql=/usr | |
make | |
make install | |
useradd nagios -G script | |
chown nagios.nagios /usr/local/nagios | |
chown -R nagios.nagios /usr/local/nagios/libexec |
git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
As configured in my dotfiles.
start new:
tmux
start new with session name:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Python regular expressions for IPv4 and IPv6 addresses and URI-references, | |
# based on RFC 3986's ABNF. | |
# | |
# ipv4_address and ipv6_address are self-explanatory. | |
# ipv6_addrz requires a zone ID (RFC 6874) follow the IPv6 address. | |
# ipv6_address_or_addrz allows an IPv6 address with optional zone ID. | |
# uri_reference is what you think of as a URI. (It uses ipv6_address_or_addrz.) | |
import re |
OlderNewer