From 4c041f52519b44a1d22abee0228de22aef9c6f6b Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Sun, 21 Aug 2016 17:12:34 +0200 Subject: [PATCH] Improved github as mirror. --- .gitlab-ci.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0858b2b9d..c9b32e4cb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,8 +2,8 @@ before_script: - ruby -v - which ruby - env - - script/build/test_db_config.sh - - bundle install + - test -n "$RNAME" && script/build/test_db_config.sh + - test -n "$RNAME" && bundle install stages: - pre @@ -35,10 +35,12 @@ pre:bundle-audit: pre:github: stage: pre + tags: + - deploy script: - git checkout $CI_BUILD_REF_NAME - git pull --rebase origin $CI_BUILD_REF_NAME - - git filter-branch --force --index-filter "git rm --cached --ignore-unmatch './.gitlab-ci.yml'" --prune-empty --tag-name-filter cat -- $CI_BUILD_REF_NAME + - git filter-branch --force --index-filter "git rm --cached --ignore-unmatch './Gemfile.lock'" --prune-empty --tag-name-filter cat -- $CI_BUILD_REF_NAME - if git remote | grep github > /dev/null; then git remote rm github; fi - git remote add github git@github.com:martini/zammad-test.git - git push github $CI_BUILD_REF_NAME