Commit fa83fc9a authored by 崔佳豪's avatar 崔佳豪

fix: Update .gitlab-ci.yml自动push

parent f01ce716
Pipeline #56771 waiting for manual action with stages
......@@ -12,8 +12,9 @@ before_script:
stages:
- install
- package
- push2021
- pushSolution
- push2021
install:
stage: install
......@@ -53,6 +54,29 @@ package:
when: manual
pushSolution:
variables:
GIT_STRATEGY: none
tags:
- civ_base
stage: pushSolution
script:
- 'cd "${TARGET_REPO_Solution}"'
- 'git reset --hard head'
- 'git clean -fd'
- 'git remote set-url origin "https://${GIT_ACCESS_USER}:${GIT_ACCESS_PASSWORD}@g.civnet.cn:8443/PandaSolution/civbase.git"'
- 'git pull origin test'
- 'git rm -rf --ignore-unmatch "${TARGET_REPO_Solution}"'
- 'robocopy "${CI_PROJECT_DIR}/../PublishTemp/civbase" "${TARGET_REPO_Solution}" /S ;
IF ((${LASTEXITCODE} -le 8)) {cmd /c "exit /b 0"}'
- 'git add . ; git commit -m "auto package civbase."'
- 'git push origin test'
only:
refs:
- master
when: on_success
push2021:
variables:
GIT_STRATEGY: none
......@@ -75,26 +99,6 @@ push2021:
only:
- master
when: manual
when: on_success
pushSolution:
variables:
GIT_STRATEGY: none
tags:
- civ_base
stage: pushSolution
script:
- 'cd "${TARGET_REPO_Solution}"'
- 'git reset --hard head'
- 'git clean -fd'
- 'git remote set-url origin "https://${GIT_ACCESS_USER}:${GIT_ACCESS_PASSWORD}@g.civnet.cn:8443/PandaSolution/civbase.git"'
- 'git pull origin test'
- 'git rm -rf --ignore-unmatch "${TARGET_REPO_Solution}"'
- 'robocopy "${CI_PROJECT_DIR}/../PublishTemp/civbase" "${TARGET_REPO_Solution}" /S ;
IF ((${LASTEXITCODE} -le 8)) {cmd /c "exit /b 0"}'
- 'git add . ; git commit -m "auto package civbase."'
- 'git push origin test'
only:
refs:
- master
when: manual
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment