Skip to content

Instantly share code, notes, and snippets.

@forsvunnet
Last active December 18, 2015 00:29
Show Gist options
  • Save forsvunnet/5697258 to your computer and use it in GitHub Desktop.
Save forsvunnet/5697258 to your computer and use it in GitHub Desktop.
Provides pretty format for git functions (NB! Prints directly to stdout)
function gt (){
if [[ $# > 1 ]]; then
g $1 --pretty=format:'%Cblue%h%Creset - %Cred%s %Cgreen(%cr)%Cblue <%an>%Creset' ${*:2} | cat -
else
echo "Usage: gt [git_function] *"
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment