tj.git-extras/bin/git-summary
Jonathan "Duke" Leto 3662dd95bf Make git-summary take an optional commitish
This allows you to ask for a git summary based on a commitish, which is
very useful if you have a lot of project history. For example, if you
want a summary since the tag v42

$ git summary v42..
2010-09-08 15:16:49 -07:00

17 lines
343 B
Bash
Executable file

#!/bin/sh
COMMITISH=""
test $# -ne 0 && COMMITISH=$@
project=${PWD##*/}
commit_count=`git log --oneline | wc -l | tr -d ' '`
file_count=`git ls-files | wc -l | tr -d ' '`
authors=`git shortlog -n -s $COMMITISH`
echo
echo " project: $project"
echo " commits: $commit_count"
echo " files : $file_count"
echo " authors: "
echo "$authors"
echo