CI: test version differently

This commit is contained in:
DevTekVE 2023-12-10 01:14:14 +01:00
parent 75d2fbf22a
commit f601c7be0b
1 changed files with 4 additions and 4 deletions

View File

@ -2,7 +2,7 @@ variables:
BUILD_DIR: "/data/openpilot"
OUTPUT_DIR: "${CI_PROJECT_DIR}/output"
CI_DIR: "${CI_PROJECT_DIR}/release/ci"
VERSION: '$(date "+%Y.%m.%d")'
VERSION: 'echo $(date "+%Y.%m.%d")'
GIT_SUBMODULE_STRATEGY: recursive
GIT_DISCOVERY_ACROSS_FILESYSTEM: 1
DEV_C3_SOURCE_BRANCH: "master-dev-c3"
@ -22,7 +22,7 @@ default:
- x86
.default_before_script: &default_before_script
- 'export VERSION=$(eval echo $VERSION)${EXTRA_VERSION_IDENTIFIER}'
- 'export VERSION=$(eval $VERSION)${EXTRA_VERSION_IDENTIFIER}'
- 'mkdir -p "${BUILD_DIR}/"'
- 'git config --global user.email "${GIT_CONFIG_USER_EMAIL}"'
- 'git config --global user.name "${GIT_CONFIG_USER_NAME}"'
@ -51,14 +51,14 @@ workflow: # If running on any branch other than main, use the `aws-datacontracts
- if: $CI_COMMIT_REF_NAME == $CI_DEFAULT_BRANCH
variables:
NEW_BRANCH: "staging-c3"
VERSION: '$(awk "/#define COMMA_VERSION/ { gsub(/\"/, \"\", \$3); gsub(/'\''/, \"\", \$3); print \$3 }" common/version.h)'
VERSION: 'cat common/version.h | grep COMMA_VERSION | sed -e "s/[^0-9|.]//g"'
EXTRA_VERSION_IDENTIFIER: "-staging"
when: always
# if tag
- if: $CI_COMMIT_TAG
variables:
NEW_BRANCH: "release-c3"
VERSION: '$(awk "/#define COMMA_VERSION/ { gsub(/\"/, \"\", \$3); gsub(/'\''/, \"\", \$3); print \$3 }" common/version.h)'
VERSION: 'cat common/version.h | grep COMMA_VERSION | sed -e "s/[^0-9|.]//g"'
EXTRA_VERSION_IDENTIFIER: "-release"
- when: always