summaryrefslogtreecommitdiff
path: root/git-changes
diff options
context:
space:
mode:
Diffstat (limited to 'git-changes')
-rwxr-xr-xgit-changes10
1 files changed, 10 insertions, 0 deletions
diff --git a/git-changes b/git-changes
new file mode 100755
index 0000000..a964d0f
--- /dev/null
+++ b/git-changes
@@ -0,0 +1,10 @@
+#!/usr/bin/env bash
+re='^[0-9]+$'
+if [[ $1 =~ $re ]]
+then
+ days=${1}
+ shift
+else
+ days='1'
+fi
+git shortlog --since=$(date -d "-${days}days" +%s) "$@"