Commit b28ea2f7 authored by Sebastian Friedl's avatar Sebastian Friedl
Browse files

Add VERSION file, get release version from env

parent 97ac4044
---
stages:
- prepare
- build
variables:
GIT_SUBMODULE_STRATEGY: recursive
GIT_SUBMODULE_STRATEGY: recursive
prepare_environment:
stage: prepare
rules:
- if: $CI_COMMIT_TAG
when: never
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
image:
name: alpine:3.14
script:
- FNT_REV="$(cat VERSION)"
- FNT_REV="${FNT_REV//[[:space:]]/}"
- echo "FNT_REV=${FNT_REV}" >> variables.env
- echo "REG_GEN=${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/gypt-fonts/${FNT_REV}" >> variables.env
artifacts:
reports:
dotenv: variables.env
tags:
- docker
build:
......
......@@ -14,7 +14,7 @@ _root_dir = Path(__file__).parent.resolve(strict=True)
_timestamp = int(time())
_copyright = '© 2021 German Young Physicists’ Tournament, with reserved Font Name ‘GYPT’.'
_version = f'0.{_timestamp}'
_version = os.getenv('FNT_REV', f'0.0.{_timestamp}')
STYLES = [
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment