summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorMartin Schanzenbach <mschanzenbach@posteo.de>2021-10-09 14:20:18 +0200
committerMartin Schanzenbach <mschanzenbach@posteo.de>2021-10-09 14:20:18 +0200
commitae41c8bcd5c4a0faddffd94aec1ab85513726a48 (patch)
tree593500f0763c28c01a1e90d456956226e3944c41 /contrib
parent0506cc074484d48d38dcca9972010f981eb58727 (diff)
BUILD: Add version from git tags
Diffstat (limited to 'contrib')
-rw-r--r--contrib/get_version.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/contrib/get_version.sh b/contrib/get_version.sh
new file mode 100644
index 000000000..2d2acf0be
--- /dev/null
+++ b/contrib/get_version.sh
@@ -0,0 +1,5 @@
+#!/bin/sh
+VERSION=$(git describe --tags | tr -d '\n')
+VERSION=${VERSION:1:${#VERSION}}
+echo $VERSION > .version
+echo $VERSION