Skip to content
Snippets Groups Projects
Commit 2226d2c6 authored by Joseph Weston's avatar Joseph Weston
Browse files

add CI stages to prepare tagged releases

parent d234e993
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,7 @@ stages: ...@@ -4,6 +4,7 @@ stages:
- build - build
- test - test
- deploy - deploy
- release
variables: variables:
# rsync is used to send documentation to our web servers: we never send any # rsync is used to send documentation to our web servers: we never send any
...@@ -120,6 +121,7 @@ build and upload conda package (manual): ...@@ -120,6 +121,7 @@ build and upload conda package (manual):
<<: *conda_job <<: *conda_job
except: except:
- master - master
- /^v[0-9]+\.[0-9]+.[0-9]+$/@kwant/kwant
when: manual when: manual
...@@ -209,17 +211,22 @@ upload dev version docs: ...@@ -209,17 +211,22 @@ upload dev version docs:
after_script: after_script:
- rm -rf ~/.ssh - rm -rf ~/.ssh
# tagged version deploy
upload docs of tagged build: .tagged-version: &tagged_version
stage: deploy only:
environment: - /^v[0-9]+\.[0-9]+.[0-9]+$/@kwant/kwant
name: production
only: gather release artifacts:
- /^v[0-9]+\.[0-9]+.[0-9]+$/@kwant/kwant <<: *tagged_version
before_script: stage: release
- mkdir -p ~/.ssh
- echo $MASTER_WEBSITE_KEY | base64 -d > ~/.ssh/id_rsa && chmod 600 ~/.ssh/id_rsa
script: script:
- rsync -rlv -e "$IGNORE_HOSTKEY" --delete doc/build/html/* kwant@kwant-project.org:doc/$(echo $CI_BUILD_TAG | sed 's/v\([0-9]\+\.[0-9]\+\)\.[0-9]\+/\1/') - ./setup.py sdist
after_script: - mkdir docs
- rm -rf ~/.ssh - mv doc/build/latex/kwant.pdf docs/kwant-doc-${CI_COMMIT_TAG//v}.pdf
- mv doc/build/html docs/html
- zip -r docs/kwant-doc-${CI_COMMIT_TAG//v}.zip docs/html
artifacts:
paths:
- docs
- dist
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment