Skip to content

Commit 0226b2d

Browse files
authored
CI: make the workflows more consistent with the other HoloViz packages (#87)
1 parent 7ea504e commit 0226b2d

File tree

2 files changed

+22
-7
lines changed

2 files changed

+22
-7
lines changed

.github/workflows/build.yaml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,18 @@ on:
66
- 'v[0-9]+.[0-9]+.[0-9]+a[0-9]+'
77
- 'v[0-9]+.[0-9]+.[0-9]+b[0-9]+'
88
- 'v[0-9]+.[0-9]+.[0-9]+rc[0-9]+'
9+
# Dry-run only
10+
workflow_dispatch:
11+
inputs:
12+
target:
13+
description: 'Build mode'
14+
type: choice
15+
options:
16+
- dryrun
17+
required: true
18+
default: dryrun
19+
schedule:
20+
- cron: '0 01 * * SUN'
921

1022
jobs:
1123
conda_build:
@@ -42,10 +54,10 @@ jobs:
4254
- name: conda build
4355
run: doit package_build $CHANS_DEV $PKG_TEST_PYTHON --test-group=all
4456
- name: conda dev upload
45-
if: (contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc'))
57+
if: (github.event_name == 'push' && (contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc')))
4658
run: doit package_upload --token=$CONDA_UPLOAD_TOKEN --label=dev
4759
- name: conda main upload
48-
if: (!(contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc')))
60+
if: (github.event_name == 'push' && !(contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc')))
4961
run: doit package_upload --token=$CONDA_UPLOAD_TOKEN --label=dev --label=main
5062
pip_build:
5163
name: Build PyPI Packages
@@ -89,6 +101,7 @@ jobs:
89101
conda activate test-environment
90102
doit ecosystem=pip package_build $PKG_TEST_PYTHON --no-pkg-test
91103
- name: pip upload
104+
if: github.event_name == 'push'
92105
run: |
93106
eval "$(conda shell.bash hook)"
94107
conda activate test-environment

.github/workflows/test.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
1-
# things not included
2-
# language
3-
# notifications - no email notifications set up
4-
5-
name: pytest
1+
name: tests
62
on:
3+
push:
4+
branches:
5+
- master
76
pull_request:
87
branches:
98
- '*'
9+
workflow_dispatch:
10+
schedule:
11+
- cron: '0 01 * * SUN'
1012

1113
jobs:
1214
test_suite:

0 commit comments

Comments
 (0)