From ff7c27ad3f31d64edf19eee4d9b9c4ad03559e3c Mon Sep 17 00:00:00 2001 From: deed Date: Tue, 5 Oct 2021 14:11:56 +0000 Subject: [PATCH] =?UTF-8?q?Ajout=20d'un=20vrai=20d=C3=A9but=20de=20CI=20?= =?UTF-8?q?=20Linux,=20Windows=20et=20Mac?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitlab-ci.yml | 62 +++++++++++++++++++++++++++++++++++--------------- 1 file changed, 44 insertions(+), 18 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6696060..1ce3dfc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,26 +1,52 @@ -stages: -- build +image: barichello/godot-ci:3.3.3 -Khanat client linux 64: - stage: build +stages: + - export + +variables: + EXPORT_NAME: khanat_client + +linux64: + stage: export tags: - Docker - image: debian:latest script: - - apt-get update - - apt-get -y upgrade - - apt-get install --no-install-recommends -y build-essential scons pkg-config libx11-dev libxcursor-dev libxinerama-dev libgl1-mesa-dev libglu-dev libasound2-dev libpulse-dev libudev-dev libxi-dev libxrandr-dev yasm wget unzip - - - wget -q https://downloads.tuxfamily.org/godotengine/3.3.3/Godot_v3.3.3-stable_linux_server.64.zip - - wget -q https://downloads.tuxfamily.org/godotengine/3.3.3/Godot_v3.3.3-stable_export_templates.tpz - - unzip Godot_v3.3.3-stable_linux_headless.64.zip - - unzip Godot_v3.3.3-stable_export_templates.tpz - - mkdir -p ~/bin ~/.cache ~/.config/godot ~/.local/share/godot/templates/$3.3.3.stable - - mv templates/* ~/.local/share/godot/templates/3.3.3.stable - - ./Godot_v3.3.3-stable_linux_headless.64 -v --export "Linux/X11" - + - mkdir -v -p $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + - godot -v --export "Linux/X11" $EXPORT_NAME_$CI_COMMIT_SHORT_SHA/$EXPORT_NAME_$CI_COMMIT_SHORT_SHA.x86_64 artifacts: - name: "khanat-$(echo $CI_BUILD_REF | head -c 7 )-$CI_PIPELINE_ID-client-linux-64" + name: $EXPORT_NAME_$CI_JOB_NAME_$CI_COMMIT_SHORT_SHA paths: + - $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + only: + - merge_requests when: manual +windows: + stage: export + tags: + - Docker + script: + - mkdir -v -p $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + - godot -v --export "Windows Desktop" $EXPORT_NAME_$CI_COMMIT_SHORT_SHA/$EXPORT_NAME_$CI_COMMIT_SHORT_SHA.exe + artifacts: + name: $EXPORT_NAME_$CI_JOB_NAME_$CI_COMMIT_SHORT_SHA + paths: + - $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + only: + - merge_requests + when: manual + +mac: + stage: export + tags: + - Docker + script: + - mkdir -v -p $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + - godot -v --export "Mac OSX" $EXPORT_NAME_$CI_COMMIT_SHORT_SHA/$EXPORT_NAME_$CI_COMMIT_SHORT_SHA.zip + artifacts: + name: $EXPORT_NAME_$CI_JOB_NAME_$CI_COMMIT_SHORT_SHA + paths: + - $EXPORT_NAME_$CI_COMMIT_SHORT_SHA + only: + - merge_requests + when: manual