Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HPCC-30610 Update build scripts to set tag timestamp #17956

Merged
merged 1 commit into from
Nov 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions cmake_modules/parse_cmake.sh
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,8 @@ function update_version_file()
local _new_sequence=$3
local _new_minor=$4
local _new_major=$5
local _new_timestamp=$(date -u "+%Y-%m-%dT%H:%M:%SZ")

if [ -z "$_new_minor" ] ; then
_new_minor=$HPCC_MINOR
fi
Expand All @@ -152,6 +154,7 @@ function update_version_file()
-e "\"s/HPCC_POINT +$HPCC_POINT *\)/HPCC_POINT $_new_point )/\"" \
-e "\"s/HPCC_SEQUENCE +$HPCC_SEQUENCE *\)/HPCC_SEQUENCE $_new_sequence )/\"" \
-e "\"s/HPCC_MATURITY +\"$HPCC_MATURITY\" *\)/HPCC_MATURITY \"$_new_maturity\" )/\"" \
-e "\"s/HPCC_TAG_TIMESTAMP.*\)/HPCC_TAG_TIMESTAMP \"$_new_timestamp\" )/\"" \
-i.bak $VERSIONFILE
fi
if [ -z "$DRYRUN" ] ; then
Expand All @@ -161,6 +164,7 @@ function update_version_file()
-e "s/HPCC_POINT +$HPCC_POINT *\)/HPCC_POINT $_new_point )/" \
-e "s/HPCC_SEQUENCE +$HPCC_SEQUENCE *\)/HPCC_SEQUENCE $_new_sequence )/" \
-e "s/HPCC_MATURITY +\"$HPCC_MATURITY\" *\)/HPCC_MATURITY \"$_new_maturity\" )/" \
-e "s/HPCC_TAG_TIMESTAMP.*\)/HPCC_TAG_TIMESTAMP \"$_new_timestamp\" )/" \
-i.bak $VERSIONFILE
cat $VERSIONFILE
else
Expand All @@ -170,6 +174,7 @@ function update_version_file()
-e "s/HPCC_POINT +$HPCC_POINT *\)/HPCC_POINT $_new_point )/" \
-e "s/HPCC_SEQUENCE +$HPCC_SEQUENCE *\)/HPCC_SEQUENCE $_new_sequence )/" \
-e "s/HPCC_MATURITY +\"$HPCC_MATURITY\" *\)/HPCC_MATURITY \"$_new_maturity\" )/" \
-e "s/HPCC_TAG_TIMESTAMP.*\)/HPCC_TAG_TIMESTAMP \"$_new_timestamp\" )/" \
$VERSIONFILE
fi
}
Expand Down
Loading