[ci] upload to package registry

This commit is contained in:
Fabian 2022-09-27 18:50:35 +02:00
parent 499ef2e252
commit 1f82ef2785

View File

@ -22,13 +22,21 @@ package_linux:
- pipenv sync --dev - pipenv sync --dev
script: script:
- VERSION=$(pipenv run python -m setuptools_scm) - VERSION=$(pipenv run python -m setuptools_scm)
- echo $VERSION - echo $VERSION | tee version.txt
- pipenv run python -m build -w - pipenv run python -m build -w
- pipenv run pyinstaller --onefile --strip --name fime_${VERSION} src/fime/main.py - pipenv run pyinstaller --onefile --strip --name fime_linux_${VERSION} src/fime/main.py
artifacts: artifacts:
paths: paths:
- version.txt
- dist/*.whl - dist/*.whl
- dist/fime_* - dist/fime_linux_*
upload:
image: curlimages/curl:latest
stage: deploy
script:
- VERSION=$(cat version.txt)
- 'curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file dist/fime_linux_${VERSION} "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/fime/${VERSION}/fime_linux_${VERSION}"'
release_job: release_job:
stage: release stage: release