View .gitconfig
This file contains 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
[user] | |
name = Person Name | |
email = you_rock@example.com | |
# I love Vim. Vimdiff is amazing. This combined with `merge.conflictstyle = diff3` | |
# makes for fun 4 pane vim sessions that make merge headaches almost all go away | |
[diff] | |
tool = vimdiff | |
compactionHeuristic = true |
View stuffs.zsh
This file contains 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/zsh | |
emulate -L zsh | |
setopt err_exit | |
if [[ $# -ne 1 ]]; then | |
printf "Usage: %s session_name\n" "$0" >&2 | |
exit 1 | |
fi | |
readonly SOCKDIR="/var/run/screen/S-${USER}" |
View ssl_dates.zsh
This file contains 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
function ssl_dates () { | |
local rem_host="${1}" | |
local rem_port="${2:-443}" | |
[[ -n $rem_host ]] || { | |
echo 'USAGE: ssl_dates host.example.com [8443]' && return 1 | |
} | |
echo '' | openssl s_client -servername "${rem_host}" -showcerts -connect "${rem_host}:${rem_port}" | openssl x509 -noout -dates | |
} |
View project_switcher.zsh
This file contains 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
setopt extendedglob | |
unset CURRENT_PROJECT_NAME | |
typeset -a project_dirs | |
find "${HOME}/projects" -maxdepth 1 -type d | while read project; do | |
project_dirs+=("${project:t}") | |
done | |
function proj() { | |
name=$1 | |
base=${2-projects} |
View heron.c
This file contains 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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
#include <stdbool.h> | |
double heron_sqrt(long n, double percision); | |
void compare_sqrt(long n); | |
int main(int argc, char **argv) | |
{ |
View run_build.zsh
This file contains 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/zsh | |
for and_target in `print -l ${ANDROID_TARGET} `;do | |
android update project -p . --subprojects -t ${and_target} -n GatekeeperAndroid | |
ant debug | |
done |
View zkbd.zsh
This file contains 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
ZKBD_FILE=${HOME}/.zkbd/$TERM-$VENDOR-$OSTYPE | |
if [[ -e $ZKBD_FILE ]] | |
then | |
source $ZKBD_FILE | |
else | |
autoload zkbd | |
zkbd | |
source $ZKBD_FILE | |
fi | |
[[ -n "${key[Home]}" ]] && bindkey "${key[Home]}" beginning-of-line |
View boto.zsh
This file contains 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
setopt extendedglob | |
typeset -a boto_web_envs | |
for cfg in `echo ~/.botocfg/(*~*.aws.cfg)`;do | |
boto_web_envs+="${cfg:t:r}" | |
done | |
benv(){ | |
if [[ "$1" == "" ]]; | |
then | |
print "Usage: $0 env-name\n" >&2 |
View output.s
This file contains 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
# From GCC 4.6.3 | |
movl GLOBAL_TIME, %eax | |
addl $1, %eax | |
movl %eax, GLOBAL_TIME | |
movl GLOBAL_TIME, %eax | |
# From Clang 3.0-6ubuntu | |
movl ALARM_TIME, %eax | |
cmpl GLOBAL_TIME, %eax | |
jne .LBB0_5 |
View updates.zsh
This file contains 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/zsh | |
# | |
echo wget -O CentOS/initrd_6_32.img "http://mirrors.rit.edu/centos/6.2/os/i386/images/pxeboot/initrd.img" | |
wget -O CentOS/initrd_6_32.img "http://mirrors.rit.edu/centos/6.2/os/i386/images/pxeboot/initrd.img" | |
echo wget -O CentOS/initrd_6_64.img "http://mirrors.rit.edu/centos/6.2/os/x86_64/images/pxeboot/initrd.img" | |
wget -O CentOS/initrd_6_64.img "http://mirrors.rit.edu/centos/6.2/os/x86_64/images/pxeboot/initrd.img" | |
echo wget -O CentOS/vmlinuz_6_32 "http://mirrors.rit.edu/centos/6.2/os/i386/images/pxeboot/vmlinuz" | |
wget -O CentOS/vmlinuz_6_32 "http://mirrors.rit.edu/centos/6.2/os/i386/images/pxeboot/vmlinuz" | |
echo wget -O CentOS/vmlinuz_6_64 "http://mirrors.rit.edu/centos/6.2/os/x86_64/images/pxeboot/vmlinuz" | |
wget -O CentOS/vmlinuz_6_64 "http://mirrors.rit.edu/centos/6.2/os/x86_64/images/pxeboot/vmlinuz" |
NewerOlder