############# # Aliases # ############# RELPATH=$(dirname "$0") command_exists "git" && source $RELPATH/alias/git command_exists "tmux" && source $RELPATH/alias/tmux command_exists "vagrant" && source $RELPATH/alias/vagrant # Interpreters command_exists "ruby" && alias rb='ruby' command_exists "python" && alias py='python' command_exists "node" && alias js='node' if is_mac && [ -e /Applications/love.app/Contents/MacOS/love ]; then alias love="/Applications/love.app/Contents/MacOS/love" fi if is_mac; then alias ls='ls -G' else alias ls='ls -G --color' fi alias l='ls -1' alias ll='ls -l' alias la='ls -la' alias l.='ls -Ad .*' alias du='du -h -d 1' alias q='exit' alias sha1='openssl sha1' alias mkdir='mkdir -pv' # Resume download if possible alias wget='wget -c' alias header='curl -I' if is_linux; then # iptables alias ipt='sudo iptables' elif is_mac; then alias b='brew' alias brewp='cd `brew --prefix`' alias ql='quick-look' fi # vim if [[ ! -n $SSH_CLIENT ]]; then if command_exists mvim; then alias v='mvim' else alias v='gvim' fi else alias v='vim' fi # vim:set ft=zsh: