Created
January 16, 2009 15:23
-
-
Save jlong/47959 to your computer and use it in GitHub Desktop.
My bash profile
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
# Environment Variables | |
export PS1="\u@\h:\w$ " | |
export PATH=$HOME/bin:/opt/local/bin:/usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin:/usr/local/git/bin:$PATH | |
export MANPATH=$MANPATH:/opt/local/share/man:/usr/local/git/man | |
export INFOPATH=$INFOPATH:/opt/local/share/info | |
export EDITOR=vi | |
export CVS_RSH=ssh | |
export DEPLOY_TO=staging | |
# Aliases | |
alias profile="vi ~/.bash_profile" | |
alias fireworks="open -a '/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app'" | |
alias photoshop="open -a '/Applications/Adobe Photoshop CS3/Adobe Photoshop CS3.app'" | |
alias illustrator="open -a '/Applications/Adobe Illustrator CS3/Adobe Illustrator CS3.app'" | |
alias preview="open -a '/Applications/Preview.app'" | |
alias xcode="open -a '/Developer/Applications/Xcode.app'" | |
alias coda="open -a '/Applications/Coda.app'" | |
alias tm=mate | |
alias stdlib='mate /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/' | |
alias gems='mate /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/' | |
alias ws='cd ~/Workspaces; ls' | |
# Changes into the project's directory. All of my projects are stored in | |
# ~/Workspaces/. Some of them are still on subversion, thus the need for all | |
# of the checks on "trunk". They often have one or more of the following | |
# subdirectories: application, prototype, mockups, artwork, or website. | |
# The command takes to parameters: the name of the project and the sub- | |
# directory. The application subdirectory is assumed if nothing is passed. | |
project () | |
{ | |
if [[ -e ~/Workspaces/$1/trunk ]] | |
then | |
if [ $2 ] | |
then | |
cd ~/Workspaces/$1/trunk/$2 | |
else | |
if [[ -e ~/Workspaces/$1/trunk/$1 ]] | |
then | |
cd ~/Workspaces/$1/trunk/$1 | |
else | |
cd ~/Workspaces/$1/trunk | |
fi | |
fi | |
else | |
if [ $2 ] | |
then | |
cd ~/Workspaces/$1/$2 | |
else | |
if [[ -e ~/Workspaces/$1/application ]] | |
then | |
cd ~/Workspaces/$1/application | |
else | |
cd ~/Workspaces/$1 | |
fi | |
fi | |
fi | |
} | |
alias pr=project | |
# MemberHub | |
mh () | |
{ | |
project memberhub $1 | |
} | |
complete -W "application prototype mockups artwork website" mh | |
# Broadsword | |
bs () | |
{ | |
project broadsword $1 | |
} | |
complete -W "application prototype mockups artwork" bs | |
# Radiant | |
ra () | |
{ | |
project radiant $1 | |
} | |
complete -W "application prototype mockups artwork" ra | |
# Announce It | |
ai () | |
{ | |
project announceit $1 | |
} | |
complete -W "application prototype mockups artwork" ra | |
# View man documentation in Preview | |
pman () | |
{ | |
man -t "${1}" | open -f -a /Applications/Preview.app/ | |
} | |
# Auto completion for Gemedit. Awesomeness. | |
complete -C "/usr/bin/gemedit --complete -e mate" gemedit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment