summaryrefslogtreecommitdiff
path: root/git-changes
blob: d048f36c8c7e6c997066c0be19cd735123469481 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/usr/bin/env bash
#
# Show a summary of changes, eg: 'git changes 2 src' shows two days of changes
# in the 'src' directory.
#
re='^[0-9]+$'
if [[ $1 =~ $re ]]
then
    days=${1}
    shift
else
    days='1'
fi
git log --invert-grep --author="Bot" \
    --format=short --since=$days.days.ago "$@" \
    | git shortlog