Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add 'git contribution' alias with fancy tracking of individual user c…

…ontribution to a specific repo
  • Loading branch information...
commit 698251fa349297cfabb31bdf40ea50b37bad4b02 1 parent 25cca23
Christopher Gateley authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  git/gitconfig.symlink
2  git/gitconfig.symlink
View
@@ -59,6 +59,8 @@
l = "!git log --abbrev-commit --date=short --pretty=format:'%x00%h%x00%cd%x00%s%x00%an%x00%d' | gawk -F '\\0' '{ printf \"%s\\033[31m%s\\033[0m \\033[32m%s\\033[0m %-80s \\033[30;1m%s\\033[0m\\033[33m%s\\n\", $1, $2, $3, gensub(/(.{79}).{2,}/, \"\\\\1…\",\"g\",$4), $5, $6 }' | less -R"
lg = "!git log --graph --color=always --abbrev-commit --date=relative --pretty=format:'%x00%h%x00%s%x00%cd%x00%an%x00%d' | gawk -F '\\0' '{ printf \"%s\\033[31m%s\\033[0m %-80s \\033[32m%14s\\033[0m \\033[30;1m%s\\033[0m\\033[33m%s\\n\", $1, $2, gensub(/(.{79}).{2,}/, \"\\\\1…\",\"g\",$3), $4, $5, $6 }' | less -R"
+ contribution = "!f() { git log --shortstat --author \"$1\" | grep \"files changed\" | awk '{files+=$1; inserted+=$4; deleted+=$6} END {print \"files changed\", files, \"lines inserted:\", inserted, \"lines deleted:\", deleted}'; }; f"
+
[mergetool]
keepBackup = true
[difftool "sourcetree"]
Please sign in to comment.
Something went wrong with that request. Please try again.