Add prerelease flag to 'config.sh'.

This commit is contained in:
Sergio Benitez 2020-01-29 14:16:50 -08:00
parent f35e3c4aca
commit f8e72d2e2e
1 changed files with 10 additions and 3 deletions

View File

@ -23,10 +23,16 @@ function relative() {
fi
}
# Full and major version of Rocket
# Versioning information. These are toggled as versions change.
ROCKET_VERSION="0.5.0-dev"
ROCKET_MAJOR_VERSION=$(echo "${ROCKET_VERSION}" | cut -d'.' -f1-2)
CURRENT_RELEASE=false
PRE_RELEASE=true
# A generated codename for this version. Use the git branch for pre-releases.
case $PRE_RELEASE in
true) VERSION_CODENAME="$(git branch --show-current)" ;;
false) VERSION_CODENAME="$(echo "${ROCKET_VERSION}" | cut -d'.' -f1-2)" ;;
esac
# Root of workspace-like directories.
PROJECT_ROOT=$(relative "") || exit $?
@ -55,8 +61,9 @@ ALL_PROJECT_DIRS=(
if [ "${1}" = "-p" ]; then
echo "ROCKET_VERSION: ${ROCKET_VERSION}"
echo "ROCKET_MAJOR_VERSION: ${ROCKET_MAJOR_VERSION}"
echo "CURRENT_RELEASE: ${CURRENT_RELEASE}"
echo "PRE_RELEASE: ${PRE_RELEASE}"
echo "VERSION_CODENAME: ${VERSION_CODENAME}"
echo "SCRIPT_DIR: ${SCRIPT_DIR}"
echo "PROJECT_ROOT: ${PROJECT_ROOT}"
echo "CORE_ROOT: ${CORE_ROOT}"