Update .gitlab-ci.yml

This commit is contained in:
Black Hat 2018-08-14 07:51:03 +00:00
parent 1c48050fc0
commit 7e0f231b1d
1 changed files with 8 additions and 27 deletions

View File

@ -1,31 +1,19 @@
stages: stages:
- preparation
- build - build
- deploy - deploy
preparation-flatpak:
image: registry.gitlab.com/b0/matrique/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: build-native:
image: registry.gitlab.com/b0/matrique/qt image: registry.gitlab.com/b0/matrique/qt
stage: build stage: build
cache: {}
before_script: before_script:
- git submodule update --init --recursive - git submodule update --init --recursive
script: script:
- mkdir -p build && cd build - mkdir -p build && cd build
- qmake ../matrique.pro -spec linux-g++ CONFIG+=qtquickcompiler - qmake ../matrique.pro -spec linux-g++ CONFIG+=qtquickcompiler
- make -j4 - make -j4
artifacts:
paths:
- build
build-flatpak: build-flatpak:
image: registry.gitlab.com/b0/matrique/flatpak image: registry.gitlab.com/b0/matrique/flatpak
@ -33,24 +21,17 @@ build-flatpak:
before_script: before_script:
- git submodule update --init --recursive - git submodule update --init --recursive
script: script:
- gpg2 -v --import <(echo "$GPG_SECRET_KEY")
- cd flatpak - cd flatpak
- flatpak-builder --repo=../tmp/matrique-repo/public build-dir org.eu.encom.matrique.json --force-clean --gpg-sign=52986BF4D61350EC249F2E891B0DB3358FC5E4B2 - flatpak-builder build-dir org.eu.encom.matrique.json --force-clean
- cd ../ - cd ../
artifacts: artifacts:
paths: paths:
- tmp/ - flatpak/build-dir
deploy-flatpak: deploy-flatpak:
only: only:
- master - master
image: registry.gitlab.com/b0/matrique/alpine tags:
stage: deploy - deploy-flatpak
before_script:
- git config --global user.name "$GIT_NAME"
- git config --global user.email "$GIT_EMAIL"
script: script:
- cd tmp/matrique-repo - echo "Nothing to do..."
- git add -A
- git commit -m "$CI_COMMIT_MESSAGE"
- git push origin master