1
1
# This file is managed by 'repo_helper'. Don't edit it directly.
2
2
---
3
- name : Linux Tests
3
+ name : Linux
4
4
5
5
on :
6
6
push :
9
9
10
10
jobs :
11
11
tests :
12
- name : " Python ${{ matrix.python-version }}"
13
- runs-on : " ubuntu-18.04"
12
+ name : " ubuntu-20.04 / Python ${{ matrix.config.python-version }}"
13
+ runs-on : " ubuntu-20.04"
14
+ continue-on-error : ${{ matrix.config.experimental }}
14
15
env :
15
- USING_COVERAGE : ' 3.6,3.7,3.8,3.9,pypy3 '
16
+ USING_COVERAGE : ' 3.6,3.7,3.8,3.9,3.10.0-alpha.3,pypy-3.6 '
16
17
17
18
strategy :
18
19
fail-fast : False
19
20
matrix :
20
- python-version : ["3.6","3.7","3.8","3.9","pypy3"]
21
+ config :
22
+ - {python-version: "3.6", testenvs: "py36,build", experimental: False}
23
+ - {python-version: "3.7", testenvs: "py37,build", experimental: False}
24
+ - {python-version: "3.8", testenvs: "py38,build", experimental: False}
25
+ - {python-version: "3.9", testenvs: "py39,build", experimental: False}
26
+ - {python-version: "3.10.0-alpha.3", testenvs: "py310-dev,build", experimental: True}
27
+ - {python-version: "pypy-3.6", testenvs: "pypy3,build", experimental: False}
21
28
22
29
steps :
23
30
- name : Checkout 🛎️
24
31
uses : " actions/checkout@v2"
32
+
25
33
- name : Setup Python 🐍
26
34
uses : " actions/setup-python@v2"
27
35
with :
28
- python-version : " ${{ matrix.python-version }}"
36
+ python-version : " ${{ matrix.config.python-version }}"
37
+
29
38
- name : Install dependencies 🔧
30
39
run : |
31
40
python -VV
32
41
python -m site
33
42
python -m pip install --upgrade pip setuptools wheel
34
- python -m pip install --upgrade tox tox-gh-actions virtualenv
43
+ python -m pip install --upgrade tox virtualenv
35
44
python -m pip install --upgrade coverage_pyver_pragma
36
45
37
- - name : " Run Tests for Python ${{ matrix.python-version }}"
38
- run : " python -m tox"
46
+ - name : " Run Tests for Python ${{ matrix.config. python-version }}"
47
+ run : python -m tox -e "${{ matrix.config.testenvs }} "
39
48
40
49
41
- - name : " Upload Coverage"
50
+ - name : " Upload Coverage 🚀 "
42
51
uses : actions/upload-artifact@v2
43
52
with :
44
- name : " coverage-${{ matrix.python-version }}"
53
+ name : " coverage-${{ matrix.config. python-version }}"
45
54
path : .coverage
46
55
47
56
48
57
Coverage :
49
58
needs : tests
50
- runs-on : " ubuntu-18 .04"
59
+ runs-on : " ubuntu-20 .04"
51
60
steps :
52
61
- name : Checkout 🛎️
53
62
uses : " actions/checkout@v2"
62
71
python -m pip install --upgrade pip setuptools wheel
63
72
python -m pip install --upgrade coveralls coverage_pyver_pragma
64
73
65
- - name : " Download Coverage"
74
+ - name : " Download Coverage 🪂 "
66
75
uses : actions/download-artifact@v2
67
76
with :
68
77
path : coverage
@@ -71,12 +80,12 @@ jobs:
71
80
run : ls -R
72
81
working-directory : coverage
73
82
74
- - name : Combine Coverage
83
+ - name : Combine Coverage 👷
75
84
run : |
76
85
shopt -s globstar
77
86
python -m coverage combine coverage/**/.coverage
78
87
79
- - name : " Upload Combined Coverage Artefact"
88
+ - name : " Upload Combined Coverage Artefact 🚀 "
80
89
uses : actions/upload-artifact@v2
81
90
with :
82
91
name : " combined-coverage"
@@ -91,27 +100,31 @@ jobs:
91
100
Deploy :
92
101
needs : tests
93
102
94
- runs-on : " ubuntu-18 .04"
103
+ runs-on : " ubuntu-20 .04"
95
104
steps :
96
105
- name : Checkout 🛎️
97
106
uses : " actions/checkout@v2"
107
+ if : startsWith(github.ref, 'refs/tags/')
98
108
99
109
- name : Setup Python 🐍
100
110
uses : " actions/setup-python@v2"
101
111
with :
102
112
python-version : 3.8
113
+ if : startsWith(github.ref, 'refs/tags/')
103
114
104
115
- name : Install dependencies 🔧
105
116
run : |
106
117
python -m pip install --upgrade pip setuptools wheel
107
118
python -m pip install --upgrade tox
119
+ if : startsWith(github.ref, 'refs/tags/')
108
120
109
121
- name : Build distributions 📦
110
122
run : |
111
123
tox -e build
112
124
125
+ if : startsWith(github.ref, 'refs/tags/')
113
126
114
- - name : Upload distribution 📦 to PyPI
127
+ - name : Upload distribution to PyPI 🚀
115
128
if : startsWith(github.ref, 'refs/tags/')
116
129
uses : pypa/gh-action-pypi-publish@master
117
130
with :
@@ -123,7 +136,8 @@ jobs:
123
136
124
137
Conda :
125
138
needs : deploy
126
- runs-on : " ubuntu-18.04"
139
+ runs-on : " ubuntu-20.04"
140
+ if : startsWith(github.ref, 'refs/tags/') || (startsWith(github.event.head_commit.message, 'Bump version') != true)
127
141
steps :
128
142
- name : Checkout 🛎️
129
143
uses : " actions/checkout@v2"
@@ -147,7 +161,6 @@ jobs:
147
161
bash .github/actions_build_conda.sh
148
162
149
163
- name : Deploy Conda 🚀
150
- if : startsWith(github.ref, 'refs/tags/')
151
164
run : |
152
165
chmod +x .github/actions_deploy_conda.sh
153
166
bash .github/actions_deploy_conda.sh
0 commit comments