version: support major.minor.patch tags without breaking Apple builds.

Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
David Anderson
2020-06-01 20:42:34 +00:00
committed by Dave Anderson
parent 984a699219
commit 5aae6b734d
8 changed files with 167 additions and 45 deletions
+3 -9
View File
@@ -1,10 +1,4 @@
ver=$(cd ../.. && git describe | sed 's/^v//')
if [ "$ver" = "${ver%-*}" ]; then
# no sub-version. ie. it's 0.05 and not 0.05-341
# so add a sub-version.
ver=$ver-0
fi
redo-ifchange mkversion.sh describe.txt
read -r describe <describe.txt
ver=$(./mkversion.sh long "$describe")
echo "$ver" >$3
redo-always
redo-stamp <$3