summaryrefslogtreecommitdiff
path: root/bin/git-blog
diff options
context:
space:
mode:
Diffstat (limited to 'bin/git-blog')
-rwxr-xr-xbin/git-blog11
1 files changed, 11 insertions, 0 deletions
diff --git a/bin/git-blog b/bin/git-blog
new file mode 100755
index 0000000..8be71e7
--- /dev/null
+++ b/bin/git-blog
@@ -0,0 +1,11 @@
+#!/bin/bash -e
+
+# Log for a branch, starting from where it diverges from its upstream.
+
+BRANCH=HEAD
+if [ $# -gt 0 ]; then
+ BRANCH="$1"
+ shift
+fi
+
+exec git log "${BRANCH}@{upstream}...${BRANCH}" "$@"