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

CI: build and optionally upload conda package in a single job

We build conda packages on 'master' (on all forks) by default.
Builds for branches may be triggered manually.
parent 92325db8
Branches
No related tags found
No related merge requests found
......@@ -3,7 +3,6 @@ image: kwant/testing
stages:
- build
- test
- package
- deploy
variables:
......@@ -82,11 +81,8 @@ check for broken links in doc:
allow_failure: true
create conda package:
stage: package
only:
- master
- /^.*-build$/
.conda-template: &conda_job
stage: deploy
image: condaforge/linux-anvil
script:
- yum install -y devtoolset-2-gcc-gfortran
......@@ -95,18 +91,26 @@ create conda package:
- conda build --python 3.5 conda-recipes/kwant-dev
- conda build --python 3.6 conda-recipes/kwant-dev
- mv /opt/conda/conda-bld/linux-64/kwant-dev*.tar.bz2 .
- if [ ! -z $ANACONDA_TOKEN ]; then anaconda --token=$ANACONDA_TOKEN upload --force kwant-dev*tar.bz2; fi
artifacts:
paths:
- kwant-dev*.tar.bz2
expire_in: 1 month
upload conda package:
stage: deploy
# build on master always
build and upload conda package:
<<: *conda_job
only:
- master@kwant/kwant
image: condaforge/linux-anvil
script:
- anaconda --token=$ANACONDA_TOKEN upload --force kwant-dev*tar.bz2
- master
# manual triggers for branches other than master possible
build and upload conda package (manual):
<<: *conda_job
except:
- master
when: manual
upload coverage:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment