summaryrefslogtreecommitdiff
path: root/versie.sh
diff options
context:
space:
mode:
authorTom Smeding <t.j.smeding@uu.nl>2024-07-13 22:16:10 +0200
committerTom Smeding <t.j.smeding@uu.nl>2024-07-13 22:16:14 +0200
commit8ebc1e27f7a19091515b8de742d486698dae4d6e (patch)
tree18051f4744d689f8f98587af661cfd39fd87c226 /versie.sh
parent712530e52091520f8f2bf347dc9ecb4030d9c4ed (diff)
omd
Diffstat (limited to 'versie.sh')
-rwxr-xr-xversie.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/versie.sh b/versie.sh
new file mode 100755
index 0000000..85aecf1
--- /dev/null
+++ b/versie.sh
@@ -0,0 +1,4 @@
+#!/usr/bin/env bash
+tag=$(git describe --tags 2>/dev/null)
+if [[ $? -eq 0 ]]; then echo "$tag"; exit; fi
+echo "vgit-$(git rev-parse --short HEAD)"