Skip to content

Commit af9df96

Browse files
committedAug 21, 2024
Make bump useable for the actual switch to 1.0.0
1 parent 1ed4831 commit af9df96

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed
 

‎bump

+13-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,20 @@
11
#!/bin/bash
22

3-
#Usage ./bump major.minor.patch
3+
#Usage ./bump [major.minor.patch]
4+
#If no release is used, reuse old release number and just add a date tag
45

56
RELEASE=$1
6-
V="${RELEASE}_$(date +%Y%m%d)"
7+
OLDRELEASE=$(grep AC_INIT configure.ac | cut -f3 -d'[' | cut -f1 -d'_' | cut -f1 -d']')
8+
if test -z "$RELEASE"
9+
then
10+
RELEASE=$OLDRELEASE
11+
fi
12+
if [ "$RELEASE" = "$OLDRELEASE" ]
13+
then
14+
V="${RELEASE}_$(date +%Y%m%d)"
15+
else
16+
V="${RELEASE}"
17+
fi
718
U=$(env LANG=en_US.UTF-8 date +'%B %d, %Y')
819
sed -e "s/AC_INIT(\([^ ,]*, *\[\)[0-9._\-]*/AC_INIT(\1$V/g" -e "s/UPDATED=\".*\"/UPDATED=\"$U\"/g" configure.ac >configure.ac+ && mv configure.ac+ configure.ac
920
dvcs ci -m "Bump version number"

0 commit comments

Comments
 (0)
Please sign in to comment.