tmux Start new session
tmux a Re-attach session
tmux a -t foo Re-attach session named foo
tmux ls List all sessions
d Detach
| if [ $UID -eq 0 ]; then NCOLOR="red"; else NCOLOR="green"; fi | |
| local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})" | |
| function gittop() { | |
| local GITDIR=`git rev-parse --show-toplevel` 2> /dev/null | |
| if [ $GITDIR ]; then | |
| echo "$(basename $GITDIR) " | |
| fi | |
| } |
| // Coffeescript | |
| foo = (x) -> { 2 * x } |
| <?php | |
| // Verbose syntax for Closure | |
| function ($x) { | |
| return $x * 2; | |
| } | |
| // Short Closure Syntax | |
| $x ~> $x * 2 |
| <?php | |
| include_once './vendor/autoload.php'; | |
| function accountExists($name){ | |
| $soapClient = new \Zimbra\ZCS\SoapClient("host", "port", "username", "password"); | |
| $admin = new \Zimbra\ZCS\Admin\Account($soapClient); | |
| try { | |
| // Fetch account by name, if it exists return it | |
| $accountEntity = $admin->getAccount($name, 'name'); |
Locate the section for your github remote in the .git/config file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
| xdebug.remote_enable=on | |
| xdebug.remote_handler=dbgp | |
| xdebug.remote_port=9000 | |
| xdebug.remote_connect_back=on | |
| xdebug.remote_autostart=on | |
| xdebug.idekey=vagrant |
| #!/bin/bash | |
| # Author: Chris Ramakers <chris@inventis.be> | |
| # Bash script to replace all tabs with spaces through the expand shell command | |
| # For more info on expand run "man expand" | |
| # Special thanks to bmk on Stackoverflow | |
| # http://stackoverflow.com/questions/6677441/run-expand-on-find-results/6683317#6683317 | |
| # This script accepts 2 arguments |
| for user in $(cut -f1 -d: /etc/passwd); do crontab -u $user -l; done |
| .DS_Store | |
| .svn/ | |
| /path/to/app/cache/* |