diff --git a/git-heatmap b/git-heatmap index daf6b35..f40261f 100755 --- a/git-heatmap +++ b/git-heatmap @@ -36,6 +36,11 @@ while [[ $# -gt 0 ]]; do shift shift ;; + -s|--since) + SINCE="$2" + shift + shift + ;; -h) cat <, --char Use to draw the bars. [default: █] -f , --filter Filter output through before creating the the histogram. + -s , --since Filter git log since . [default: always] -h Show this message. EOF exit @@ -67,10 +73,11 @@ REVIEW_BASE=${REVIEW_BASE:-master} CHAR=${CHAR:-█} WIDTH=${WIDTH:-60} FILTER=${FILTER:-cat -} +SINCE=${SINCE:-0001-01-01} files() { # https://stackoverflow.com/questions/7577052/ - git log --name-status --pretty=format: -- "${ARGV[@]+"${ARGV[@]}"}" | \ + git log --since="$SINCE" --name-status --pretty=format: -- "${ARGV[@]+"${ARGV[@]}"}" | \ cut -f 2- }