]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: scripts: automatically update the branch in version.h when releasing
authorWilly Tarreau <w@1wt.eu>
Thu, 5 Jan 2017 18:58:24 +0000 (19:58 +0100)
committerWilly Tarreau <w@1wt.eu>
Thu, 5 Jan 2017 19:00:25 +0000 (20:00 +0100)
The stats page proudly displays "Updates (v1.5)". This version is inherited
from version.h which has not been updated since 1.5, so let's teach the
create-release script about it.

This must be backported to 1.7. 1.6 now uses the same script (externally)
for the release and will automatically benefit from it.

scripts/create-release

index 35688f0fb77b9835ed482658936724b89eeb5d18..21649c97d176c7fb51a1a64c2ae38ad9e6811a85 100755 (executable)
@@ -192,6 +192,10 @@ echo "Updating haproxy.c ..."
 sed -e "s:Copyright 2000-[0-9]*\s*Willy Tarreau.*>:Copyright 2000-$YEAR Willy Tarreau <willy@haproxy.org>:" \
     -i src/haproxy.c
 
+echo "Updating version.h ..."
+sed -e "s:^\(#define\s*PRODUCT_BRANCH\s*\)\"[^\"]*\":\1\"$BRANCH\":" \
+    -i include/common/version.h
+
 if [ -n "$INTERACTIVE" ]; then
        vi CHANGELOG VERSION VERDATE examples/haproxy*.spec \
           src/haproxy.c README doc/configuration.txt \