aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2018-09-20 01:03:09 -0700
committerH. Peter Anvin <hpa@zytor.com>2018-09-20 01:05:13 -0700
commitaae3d95ec043bf55468d8de2d11eb860189bf83a (patch)
tree9efc8c20ab57b8671b6da6b397eef241e41c9e59
parent633a125ec362f0a8938be03891bb32c2e2a21cb9 (diff)
downloadabc80sim-aae3d95ec043bf55468d8de2d11eb860189bf83a.tar.gz
abc80sim-aae3d95ec043bf55468d8de2d11eb860189bf83a.tar.xz
abc80sim-aae3d95ec043bf55468d8de2d11eb860189bf83a.zip
tag: simple script to create a new release tag
-rwxr-xr-xtag18
1 files changed, 18 insertions, 0 deletions
diff --git a/tag b/tag
new file mode 100755
index 0000000..15ccfea
--- /dev/null
+++ b/tag
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+project='abc80sim'
+
+if [ -z "$1" ]; then
+ echo "Usage: $0 version" 1>&2
+ exit 1
+fi
+
+if [ "$(git diff --cached | wc -l)" != 0 ]; then
+ echo "$0: changes already in git cache" 1>&2
+ exit 1
+fi
+
+echo "#define VERSION \"$1\"" > patchlevel.h
+git add patchlevel.h
+git commit -m "$project $1"
+git tag -a -m "$project $1" "$project-$1"