From c3541aeabcf7a4332b24a0f33460eb307591df19 Mon Sep 17 00:00:00 2001 From: Charles JAVERLIAT <charles.javerliat@insa-lyon.fr> Date: Sun, 10 May 2020 19:55:04 +0200 Subject: [PATCH] ci/Add tags deploy --- .gitlab-ci.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f96bf73..c97a8f5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,6 +16,19 @@ before_script: - git config --global user.email "noreply@clubelek.fr" - git config --global user.name "Compiler bot" +add_tags: + stage: deploy + script: + - echo "$SSH_PRIVATE_KEY_NANOPB" | tr -d '\r' | ssh-add - + - git remote add nanopb_dst $NANOPB_GIT_URL + - git fetch nanopb_dst + - echo "Tag is $CI_COMMIT_SHA" + - echo "Commit SHA is $CI_COMMIT_SHA" + - export $DST_COMMIT="`git log nanopb_dst/master --pretty='%H' --all --grep='messages-schemas/$CI_COMMIT_SHA'`" + - echo "Corresponding commit in nanopb is $DST_COMMIT" + only: + - tags + build: stage: build script: -- GitLab