start new:
tmux
start new with session name:
tmux new -s myname
| i | |
| me | |
| my | |
| myself | |
| we | |
| our | |
| ours | |
| ourselves | |
| you | |
| your |
| Latency Comparison Numbers (~2012) | |
| ---------------------------------- | |
| L1 cache reference 0.5 ns | |
| Branch mispredict 5 ns | |
| L2 cache reference 7 ns 14x L1 cache | |
| Mutex lock/unlock 25 ns | |
| Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
| Compress 1K bytes with Zippy 3,000 ns 3 us | |
| Send 1K bytes over 1 Gbps network 10,000 ns 10 us | |
| Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD |
A ZSH theme optimized for people who use:
See the original gist for more details.
| packages: | |
| yum: | |
| gcc-c++: [] | |
| make: [] | |
| sources: | |
| /home/ec2-user: http://download.redis.io/releases/redis-2.8.4.tar.gz | |
| commands: | |
| redis_build: | |
| command: make | |
| cwd: /home/ec2-user/redis-2.8.4 |
Command Line
pry -r ./config/app_init_file.rb - load your app into a pry session (look at the file loaded by config.ru)pry -r ./config/environment.rb - load your rails into a pry sessionDebugger
brew install fish
curl -L https://get.oh-my.fish | fish| """ | |
| this code is not mine! i shamelessly copied it from http://stackoverflow.com/questions/19790188/expanding-english-language-contractions-in-python | |
| all credits go to alko and arturomp @ stack overflow. | |
| basically, it's a big find/replace. | |
| """ | |
| import re | |
| cList = { | |
| "ain't": "am not", |
| # migrating from https://github.com/robbyrussell/oh-my-zsh/blob/master/plugins/git/git.plugin.zsh | |
| # Aliases | |
| alias g='git' | |
| #compdef g=git | |
| alias gst='git status' | |
| #compdef _git gst=git-status | |
| alias gd='git diff' | |
| #compdef _git gd=git-diff | |
| alias gdc='git diff --cached' |
My objective is to have some production files ignored on specific branches. Git doesn't allow to do it.
My solution is to make a general .gitignore file and add .gitignore.branch_name files for the branches I want to add specific file exclusion.
I'll use post-checkout hook to copy those .gitignore.branch_name in place of .git/info/exclude each time I go to the branch with git checkout branch_name.