version: support major.minor.patch tags without breaking Apple builds.
Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
committed by
Dave Anderson
parent
984a699219
commit
5aae6b734d
+4
-18
@@ -1,18 +1,4 @@
|
||||
redo-ifchange long.txt
|
||||
read -r LONGVER junk <long.txt
|
||||
|
||||
# Convert a version like "0.92-98-g123456" into "0.92-98".
|
||||
# Sometimes the version is just "0.92-0", in which case we leave it as is.
|
||||
case $LONGVER in
|
||||
*-*-*)
|
||||
echo "${LONGVER%-*}" >$3
|
||||
;;
|
||||
*-*)
|
||||
echo "$LONGVER" >$3
|
||||
;;
|
||||
*)
|
||||
echo "Fatal: long version in invalid format." >&2
|
||||
exit 44
|
||||
esac
|
||||
|
||||
redo-stamp <$3
|
||||
redo-ifchange mkversion.sh describe.txt
|
||||
read -r describe <describe.txt
|
||||
ver=$(./mkversion.sh short "$describe")
|
||||
echo "$ver" >$3
|
||||
|
||||
Reference in New Issue
Block a user