Last active
September 26, 2015 16:28
-
-
Save jonchretien/1125984 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
# Apache | |
alias config="mate /etc/apache2/httpd.conf" | |
alias webstart="sudo apachectl start" | |
alias webstop="sudo apachectl stop" | |
alias webrestart="sudo apachectl restart" | |
alias vhosts="mate /etc/apache2/extra/httpd-vhosts.conf" | |
# Git | |
alias add="git add" | |
alias branch="git branch" | |
alias clone="git clone" | |
alias checkout="git checkout" | |
alias co="git checkout" | |
alias commit="git commit" | |
alias diff="git diff" | |
alias github="cd ~/Sites/_github" | |
alias glog="git log --format='%Cgreen%h%Creset %C(cyan)%an%Creset - %s' --graph" | |
alias merge="git merge" | |
alias pull="git pull" | |
alias push="git push" | |
alias rebase="git rebase" | |
alias stash="git stash" | |
alias status="git status -sb" | |
alias tag="git tag" | |
# MySQL | |
alias mysql=/usr/local/mysql/bin/mysql | |
alias mysqladmin=/usr/local/mysql/bin/mysqladmin | |
alias mystart="mysql.server start" | |
alias mystop="mysql.server stop" | |
# Personal Aliases | |
alias cl='clear' | |
alias sites='cd ~/Sites' | |
alias bp='~/bin/bp.sh' | |
alias new='~/bin/project.sh' | |
alias showhidden='defaults write com.apple.finder AppleShowAllFiles TRUE; killall Finder' | |
alias hidehidden='defaults write com.apple.finder AppleShowAllFiles FALSE; killall Finder' | |
# Show GIT Branch | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
} | |
# Install a grunt plugin and save to devDependencies | |
function gi() { | |
npm install --save-dev grunt-"$@" | |
} | |
# Install a grunt-contrib plugin and save to devDependencies | |
function gci() { | |
npm install --save-dev grunt-contrib-"$@" | |
} | |
# Prompt Theme | |
export PS1="\[\e[0;36m\]\u\[\e[0m\]@\[\e[31m\]\h \[\e[0;36m\]\t\[\e[93m\] \w\[\e[36m\]\[\033[32m\]\$(parse_git_branch)\[\033[00m\] $ " |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment