From f1a48c521472bde1c8668e29f8c5c792e1dd9f9f Mon Sep 17 00:00:00 2001 From: winter Date: Sat, 18 Jan 2025 22:41:17 +0000 Subject: init script & fix the version info thing yeah so turns out $Id$ is not what it seems --- bin/update-version | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 bin/update-version (limited to 'bin/update-version') diff --git a/bin/update-version b/bin/update-version new file mode 100755 index 0000000..b9b3d21 --- /dev/null +++ b/bin/update-version @@ -0,0 +1,9 @@ +#!/bin/bash +cd "$(dirname "$0")" || exit 1 +[ -L "$(basename "$0")" ] && cd "$(dirname "$(readlink "$(basename "$0")")")" +if ! git describe --tags 2>/dev/null > ../VERSION; then + printf 'git ' > ../VERSION + git rev-parse --short HEAD >> ../VERSION +fi +printf 'stored version: ' +cat ../VERSION \ No newline at end of file -- cgit v1.3