Last active
August 29, 2015 14:13
-
-
Save danish-rehman/c18a2f802f4ff96d6805 to your computer and use it in GitHub Desktop.
Git config
This file contains hidden or 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
function parse_git_branch { | |
ref=$(git symbolic-ref HEAD 2> /dev/null) || return | |
ref=${ref#refs/heads/} | |
unpushed=$(git log -- origin/$ref..$ref 2> /dev/null) || return | |
if [ "$unpushed" ]; then | |
warn=' - UNPUSHED!' | |
fi | |
echo "("$ref$warn")" | |
} |
This file contains hidden or 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
[alias] | |
diffw = diff --color-words | |
lol = log --graph --decorate --pretty=oneline --abbrev-commit | |
lola = log --graph --decorate --pretty=oneline --abbrev-commit --all | |
glog = log --graph --full-history --all --color --date=short --pretty=format:'%x1b[31m%h%x09%x1b[32m%d%x1b[0m%x20%ad %aE %s' | |
merge = merge --no-ff | |
[core] | |
whitespace=fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
[color] | |
ui = auto | |
[user] | |
name = Danish Rehman | |
email = [email protected] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment