mirror of
https://github.com/mongodb/mongo.git
synced 2024-11-22 04:59:34 +01:00
314c4a7639
GitOrigin-RevId: aa93268de046c3eaf21b61b05e6081dd35793e5a
25 lines
872 B
Bash
Executable File
25 lines
872 B
Bash
Executable File
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" > /dev/null 2>&1 && pwd)"
|
|
. "$DIR/../prelude.sh"
|
|
|
|
cd src
|
|
|
|
set -o errexit
|
|
set -o verbose
|
|
# We get the raw version string (r1.2.3-45-gabcdef) from git
|
|
MONGO_VERSION=$(git describe --abbrev=7)
|
|
|
|
# If the project is sys-perf (or related), add the string -sys-perf to the version
|
|
if [[ "${project}" == sys-perf* ]]; then
|
|
MONGO_VERSION="$MONGO_VERSION-sys-perf"
|
|
fi
|
|
|
|
# If this is a patch build, we add the patch version id to the version string so we know
|
|
# this build was a patch, and which evergreen task it came from
|
|
if [ "${is_patch}" = "true" ]; then
|
|
MONGO_VERSION="$MONGO_VERSION-patch-${version_id}"
|
|
fi
|
|
echo "MONGO_VERSION = ${MONGO_VERSION}"
|
|
|
|
activate_venv
|
|
MONGO_VERSION=${MONGO_VERSION} IS_PATCH=${is_patch} IS_COMMIT_QUEUE=${is_commit_queue} $python buildscripts/generate_version_expansions.py --out version_expansions.yml
|