Reordered checkout in gitlab-ci script

Reordered checkout so it doesnt error out on overwriting untracked files.
This commit is contained in:
BARICHELLO
2018-10-31 00:57:38 -03:00
parent 1362d97c87
commit 65bfe69015
2 changed files with 2 additions and 3 deletions

View File

@@ -65,12 +65,11 @@ deploy-github-pages:
- web - web
script: script:
- cd ../ - cd ../
- git checkout gh-pages
- mv game/build/web/** . - mv game/build/web/** .
- rm README.md
- git config user.email artur@barichello.me - git config user.email artur@barichello.me
- git config user.name abarichello - git config user.name abarichello
- git remote add github $REMOTE_URL - git remote add github $REMOTE_URL
- git checkout gh-pages
- git add -A - git add -A
- 'git commit -m "Auto: Deploy GitHub Page $EXPORT_NAME-$CI_JOB_NAME$" -m "Deploy from GitLab pipeline \#$CI_PIPELINE_ID"' - 'git commit -m "Auto: Deploy GitHub Page $EXPORT_NAME-$CI_JOB_NAME$" -m "Deploy from GitLab pipeline \#$CI_PIPELINE_ID"'
- git push github gh-pages -f - git push github gh-pages -f

View File

@@ -12,5 +12,5 @@ After adapting the paths and names according to your project needs you will need
|-|-|-| |-|-|-|
|$REMOTE_URL | The `git remote` where the web export will be hosted (in this case GitHub), it should contain your [deploy/personal access token](https://github.com/settings/tokens)|`https://<github username>:<deploy token>@github.com/<username>/<repository>.git` |$REMOTE_URL | The `git remote` where the web export will be hosted (in this case GitHub), it should contain your [deploy/personal access token](https://github.com/settings/tokens)|`https://<github username>:<deploy token>@github.com/<username>/<repository>.git`
Others variables are set automatically by the `gitlab-runner` Others variables are set automatically by the `gitlab-runner`<br>
The included `gitlab-ci.yml` is set to only run the export jobs when you commit a new `git tag`, i suggest not using "." or "," in your tag's name since it messes with Godot's export system and will lead to failed jobs. The included `gitlab-ci.yml` is set to only run the export jobs when you commit a new `git tag`, i suggest not using "." or "," in your tag's name since it messes with Godot's export system and will lead to failed jobs.