-
Notifications
You must be signed in to change notification settings - Fork 13
62 lines (56 loc) · 1.71 KB
/
build_conda_recipes.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: deploy
on:
push:
branches:
- master
- dev
env:
atoken: ${{ secrets.ANACONDA_UPLOAD_TOKEN }}
recipe_path: conda/recipe
env_yml_path: conda/env/yml
#env_lock_path: conda/env/lock
VERSION: '0.6.1' # versioned by bump2version
jobs:
create_tag:
if: "startsWith(github.event.head_commit.message, 'Bump version:')"
name: Create tag
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
steps:
- name: 🔖 Tag creation
uses: actions/github-script@v5
with:
script: |
const the_tag_name = 'refs/tags/v' + process.env.VERSION
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: the_tag_name,
sha: context.sha
})
build_conda_pkgs:
# When merging to one of the branches above and the commit message matches
if: "startsWith(github.event.head_commit.message, 'Bump version:')"
name: Build conda packages
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Mambaforge
uses: conda-incubator/setup-miniconda@v2
with:
miniforge-variant: Mambaforge
miniforge-version: 4.11.0-0
show-channel-urls: true
auto-activate-base: false
activate-environment: condabuild
environment-file: ${{ env.env_yml_path }}/condabuild.yml
use-mamba: true
- name: Build + upload vcf2tsvpy conda pkg
run: |
conda mambabuild ${recipe_path} -c conda-forge -c bioconda --token ${atoken} --quiet