Skip to content

Commit 0ff7c37

Browse files
committed
CDRIVER-3573 only hardcode version for GitHub PRs and patch builds
1 parent 79c23cb commit 0ff7c37

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

.evergreen/config.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,11 @@ functions:
2424
set -o errexit
2525
set -o xtrace
2626
# TODO: CDRIVER-3573 do not hardcode the version.
27-
if [ -n "${github_pr_number}" ]; then
28-
# This is a GitHub PR, probably branched from master
27+
if [ -n "${github_pr_number}" -o "${is_patch}" = "true" ]; then
28+
# This is a GitHub PR or patch build, probably branched from master
2929
VERSION_CURRENT="1.18.0"
3030
echo $VERSION_CURRENT > "VERSION_CURRENT"
3131
VERSION=$VERSION_CURRENT-${version_id}
32-
elif [ "${is_patch}" = "true" ]; then
33-
VERSION=$(git describe --abbrev=7 --match='1.*')-patch-${version_id}
3432
else
3533
VERSION=latest
3634
fi

build/evergreen_config_lib/functions.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,11 @@
2828
]))]),
2929
shell_mongoc(r'''
3030
# TODO: CDRIVER-3573 do not hardcode the version.
31-
if [ -n "${github_pr_number}" ]; then
32-
# This is a GitHub PR, probably branched from master
31+
if [ -n "${github_pr_number}" -o "${is_patch}" = "true" ]; then
32+
# This is a GitHub PR or patch build, probably branched from master
3333
VERSION_CURRENT="1.18.0"
3434
echo $VERSION_CURRENT > "VERSION_CURRENT"
3535
VERSION=$VERSION_CURRENT-${version_id}
36-
elif [ "${is_patch}" = "true" ]; then
37-
VERSION=$(git describe --abbrev=7 --match='1.*')-patch-${version_id}
3836
else
3937
VERSION=latest
4038
fi

0 commit comments

Comments
 (0)