aboutsummaryrefslogtreecommitdiff
path: root/repo/git/cpt-bump
diff options
context:
space:
mode:
Diffstat (limited to 'repo/git/cpt-bump')
-rwxr-xr-xrepo/git/cpt-bump12
1 files changed, 12 insertions, 0 deletions
diff --git a/repo/git/cpt-bump b/repo/git/cpt-bump
new file mode 100755
index 0000000..e4b758f
--- /dev/null
+++ b/repo/git/cpt-bump
@@ -0,0 +1,12 @@
+#!/bin/sh
+# Commit the current directory as a version bump
+
+case "$1" in --help|-h) printf '%s\n' "usage: ${0##*/}"; exit 0 ; esac
+
+read ver _ < version || {
+ printf '%s\n' "could not find version file, are you on a package directory?"
+ exit 1
+}
+
+git reset; git add .
+git commit -m "${PWD##*/}: bump to $ver"