Skip to content

Instantly share code, notes, and snippets.

@ayakix
ayakix / zsh_history_sort.py
Created October 11, 2012 11:50 — forked from nishio/git_stat.py
show active command on Zsh
from collections import Counter, defaultdict
import sys
try:
#FILENAME = "/Users/{hoge}/.zhistory"
FILENAME = sys.argv[1]
except:
print "USAGE: zsh_history_sort.py <your_history_file>"
sys.exit(1)
@ayakix
ayakix / brew_install_git_logs
Created March 4, 2012 07:06 — forked from irasally/brew_install_git_logs
$brew install git is faild.(Mac OS X 10.6.8/ XCode 4.2)
$ brew install git
==> Downloading http://git-core.googlecode.com/files/git-1.7.9.2.tar.gz
File already downloaded in /Users/xxx/Library/Caches/Homebrew
==> make prefix=/usr/local/Cellar/git/1.7.9.2 CC=/usr/bin/llvm-gcc CFLAGS=-Os -w -pipe -march=core2 -msse4.1 LDFLAGS= install
GIT_VERSION = 1.7.9.2
* new build flags or prefix
* new link flags
./generate-cmdlist.sh > common-cmds.h+ && mv common-cmds.h+ common-cmds.h
rm -f git-am git-am+ && sed -e '1s|#!.*/sh|#!/bin/sh|' -e 's|@SHELL_PATH@|/bin/sh|' -e 's|@@DIFF@@|diff|' -e 's/@@GIT_VERSION@@/1.7.9.2/g' -e 's|@@LOCALEDIR@@|/usr/local/Cellar/git/1.7.9.2/share/locale|g' -e 's/@@NO_CURL@@//g' -e '/^# @@BROKEN_PATH_FIX@@$/d' git-am.sh >git-am+ && \
chmod +x git-am+ && \
@ayakix
ayakix / brew_install_git_logs
Created March 4, 2012 07:06 — forked from irasally/brew_install_git_logs
$brew install git is faild.(Mac OS X 10.6.8/ XCode 4.2)
$ brew install git
==> Downloading http://git-core.googlecode.com/files/git-1.7.9.2.tar.gz
File already downloaded in /Users/xxx/Library/Caches/Homebrew
==> make prefix=/usr/local/Cellar/git/1.7.9.2 CC=/usr/bin/llvm-gcc CFLAGS=-Os -w -pipe -march=core2 -msse4.1 LDFLAGS= install
GIT_VERSION = 1.7.9.2
* new build flags or prefix
* new link flags
./generate-cmdlist.sh > common-cmds.h+ && mv common-cmds.h+ common-cmds.h
rm -f git-am git-am+ && sed -e '1s|#!.*/sh|#!/bin/sh|' -e 's|@SHELL_PATH@|/bin/sh|' -e 's|@@DIFF@@|diff|' -e 's/@@GIT_VERSION@@/1.7.9.2/g' -e 's|@@LOCALEDIR@@|/usr/local/Cellar/git/1.7.9.2/share/locale|g' -e 's/@@NO_CURL@@//g' -e '/^# @@BROKEN_PATH_FIX@@$/d' git-am.sh >git-am+ && \
chmod +x git-am+ && \