Spectral/.gitlab-ci.yml

56 lines
1.3 KiB
YAML

stages:
- preparation
- build
- deploy
preparation-flatpak:
image: black0/alpine
stage: preparation
before_script:
- mkdir -p tmp
script:
- cd tmp
- git clone "https://$GIT_USERNAME:$GIT_PASSWORD@gitlab.com/b0/matrique-repo"
- cd ../
artifacts:
paths:
- tmp/
build-native:
image: rabits/qt:5.11-desktop
stage: build
cache: {}
before_script:
- git submodule update --init --recursive
script:
- mkdir -p build && cd build
- qmake ../matrique.pro -spec linux-g++ CONFIG+=qtquickcompiler
- make -j4
build-flatpak:
image: black0/flatpak
stage: build
before_script:
- git submodule update --init --recursive
script:
- gpg2 -v --import <(echo "$GPG_SECRET_KEY")
- cd flatpak
- flatpak-builder --repo=../tmp/matrique-repo/public build-dir org.eu.encom.matrique.json --force-clean --gpg-sign=52986BF4D61350EC249F2E891B0DB3358FC5E4B2
- cd ../
artifacts:
paths:
- tmp/
deploy-flatpak:
only:
- master
image: black0/alpine
stage: deploy
before_script:
- git config --global user.name "$GIT_NAME"
- git config --global user.email "$GIT_EMAIL"
script:
- cd tmp/matrique-repo
- git add -A
- git commit -m "$CI_COMMIT_MESSAGE"
- git push origin master