git config --global alias.hist "log --pretty=format:'%h %ad | %s%d [%an]' --graph --date=short"
git config --global alias.lol "log --graph --decorate --pretty=oneline --abbrev-commit --all"
git config --global alias.mylog "log --pretty=format:'%h %s [%an]' --graph"
git config --global alias.last 'log -1 HEAD'
git config --global alias.s 'status -s'
To check that they've been added correctly, first run git config --list
. You should see something like this in the midst of all your other configuration: