Skip to content

Instantly share code, notes, and snippets.

@akmandev
Last active July 9, 2019 12:21
Show Gist options
  • Save akmandev/2b6001e217c37b9936b47585608cd929 to your computer and use it in GitHub Desktop.
Save akmandev/2b6001e217c37b9936b47585608cd929 to your computer and use it in GitHub Desktop.
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
alias cdr="cd ~/Repositories"
alias phpunit="./vendor/bin/phpunit"
alias unixtime="date +%s"
alias c="clear"
gc() {
git fetch
git checkout $1
}
gcl() {
if [ ! -z "$2" ] then
git checkout $2
git pull
git checkout -b $1 $2
else
git checkout develop
git pull
git checkout -b $1 develop
fi
}
git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
export PS1="@\[$(tput bold)\]\u\[$(tput sgr0)\] \W \[\033[00;32m\]\$(git_branch)\[\033[00m\]\\$: \[$(tput sgr0)\]"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment