.gitlab-ci.yml simplified

This commit is contained in:
Oscar Krause 2023-01-16 10:23:58 +01:00
parent 2f3c7d5433
commit 5425eec545
1 changed files with 5 additions and 15 deletions

View File

@ -97,7 +97,7 @@ build:pacman:
- "*.pkg.tar.zst"
test:
image: python:3.10-slim-bullseye
image: python:3.11-slim-bullseye
stage: test
rules:
- if: $CI_COMMIT_BRANCH
@ -113,6 +113,9 @@ test:
- cd test
script:
- pytest main.py
artifacts:
reports:
dotenv: version.env
.test:linux:
stage: test
@ -271,24 +274,11 @@ deploy:pacman:
- 'echo "EXPORT_NAME: ${EXPORT_NAME}"'
- 'curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file ${EXPORT_NAME} "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/${PACKAGE_NAME}/${PACKAGE_VERSION}/${EXPORT_NAME}"'
release:prepare:
stage: .pre
rules:
- if: $CI_COMMIT_TAG
when: never
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
script:
- source version.env
- echo $VERSION
artifacts:
reports:
dotenv: version.env
release:
image: registry.gitlab.com/gitlab-org/release-cli:latest
stage: .post
needs:
- job: release:prepare
- job: test
artifacts: true
rules:
- if: $CI_COMMIT_TAG