Setting up .bash_profile

It is essential to setup .bash profile when working in the Terminal.

It makes life a lot easier especially when working with git.

To setup .bash_profile go to ~/.bash_profile and open in nano. Then enter any useful aliases.

Example commands like below are useful. Then after saving the file ensure to use

source ~/.bash_profile or . ~/.bash_profile to register the changes.



# Shprtcuts
alias ..="cd .."
alias ...="cd ../.."
alias h='cd ~'
alias c='clear'
alias art='php artisan'

# Git Aliases
alias gs='git status'
alias gl='git log --oneline'
alias gl5='git log --oneline -5'
alias gl10='git log --oneline -10'
alias nah='git reset --hard && git clean -df'
alias gfp="git fetch origin --prune"
alias gpod="git pull origin develop"
alias gpom="git pull origin master"