Skip to content

Commit 0e2f11c

Browse files
authored
Fix wrongly running macOS workflow on Ubuntu (#248)
1 parent f45e3ff commit 0e2f11c

File tree

8 files changed

+216
-173
lines changed

8 files changed

+216
-173
lines changed

.github/workflows/checks.yml

Lines changed: 41 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,50 @@
1+
---
12
name: Checks
23

34
on:
4-
push:
5-
branches:
6-
- master
7-
pull_request:
8-
branches:
9-
- master
5+
push:
6+
branches:
7+
- master
8+
pull_request:
9+
branches:
10+
- master
1011

1112
jobs:
12-
build:
13+
build:
14+
runs-on: ubuntu-latest
1315

14-
runs-on: ubuntu-latest
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
include:
19-
- python-version: "3.13" # Keep in sync with .readthedocs.yml
20-
env:
21-
TOXENV: docs
22-
- python-version: "3.13"
23-
env:
24-
TOXENV: pre-commit
25-
- python-version: "3.13"
26-
env:
27-
TOXENV: pylint
28-
- python-version: "3.13"
29-
env:
30-
TOXENV: typing
31-
- python-version: "3.13"
32-
env:
33-
TOXENV: twinecheck
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
include:
20+
# Keep in sync with .readthedocs.yml
21+
- python-version: '3.13'
22+
env:
23+
TOXENV: docs
24+
- python-version: '3.13'
25+
env:
26+
TOXENV: pre-commit
27+
- python-version: '3.13'
28+
env:
29+
TOXENV: pylint
30+
- python-version: '3.13'
31+
env:
32+
TOXENV: typing
33+
- python-version: '3.13'
34+
env:
35+
TOXENV: twinecheck
3436

35-
steps:
36-
- uses: actions/checkout@v4
37+
steps:
38+
- uses: actions/checkout@v4
3739

38-
- name: Set up Python ${{ matrix.python-version }}
39-
uses: actions/setup-python@v5
40-
with:
41-
python-version: ${{ matrix.python-version }}
40+
- name: Set up Python ${{ matrix.python-version }}
41+
uses: actions/setup-python@v5
42+
with:
43+
python-version: ${{ matrix.python-version }}
4244

43-
- name: Run check
44-
env: ${{ matrix.env }}
45-
run: |
46-
pip install --upgrade pip
47-
pip install --upgrade tox
48-
tox
45+
- name: Run check
46+
env: ${{ matrix.env }}
47+
run: |
48+
pip install --upgrade pip
49+
pip install --upgrade tox
50+
tox

.github/workflows/publish.yml

Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,36 @@
1+
---
12
name: Publish
23

34
on:
4-
push:
5-
tags:
6-
- v*
5+
push:
6+
tags:
7+
- v*
78

89
jobs:
9-
publish:
10-
runs-on: ubuntu-latest
10+
publish:
11+
runs-on: ubuntu-latest
1112

12-
steps:
13-
- uses: actions/checkout@v4
13+
steps:
14+
- uses: actions/checkout@v4
1415

15-
- name: Set up Python 3.13
16-
uses: actions/setup-python@v5
17-
with:
18-
python-version: 3.13
16+
- name: Set up Python 3.13
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: '3.13'
1920

20-
- name: Check Tag
21-
id: check-release-tag
22-
run: |
23-
if [[ ${{ github.event.ref }} =~ ^refs/tags/v[0-9]+[.][0-9]+[.][0-9]+(rc[0-9]+|[.]dev[0-9]+)?$ ]]; then
24-
echo ::set-output name=release_tag::true
25-
fi
21+
- name: Check Tag
22+
id: check-release-tag
23+
run: |
24+
RE="^refs/tags/v[0-9]+[.][0-9]+[.][0-9]+(rc[0-9]+|[.]dev[0-9]+)?$"
25+
if [[ ${{ github.event.ref }} =~ $RE ]]; then
26+
echo ::set-output name=release_tag::true
27+
fi
2628
27-
- name: Publish to PyPI
28-
if: steps.check-release-tag.outputs.release_tag == 'true'
29-
run: |
30-
pip install --upgrade build twine
31-
python -m build
32-
export TWINE_USERNAME=__token__
33-
export TWINE_PASSWORD=${{ secrets.PYPI_TOKEN }}
34-
twine upload dist/*
29+
- name: Publish to PyPI
30+
if: steps.check-release-tag.outputs.release_tag == 'true'
31+
run: |
32+
pip install --upgrade build twine
33+
python -m build
34+
export TWINE_USERNAME=__token__
35+
export TWINE_PASSWORD=${{ secrets.PYPI_TOKEN }}
36+
twine upload dist/*

.github/workflows/tests-macos.yml

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,44 @@
1+
---
12
name: macOS
23

34
on:
4-
push:
5-
branches:
6-
- master
7-
pull_request:
8-
branches:
9-
- master
5+
push:
6+
branches:
7+
- master
8+
pull_request:
9+
branches:
10+
- master
1011

1112
jobs:
12-
tests:
13+
tests:
14+
runs-on: macos-latest
1315

14-
runs-on: ubuntu-latest
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14.0-rc.1"]
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
python-version:
20+
- '3.9'
21+
- '3.10'
22+
- '3.11'
23+
- '3.12'
24+
- '3.13'
25+
- 3.14.0-rc.1
26+
- pypy3.10
27+
- pypy3.11
1928

20-
steps:
21-
- uses: actions/checkout@v4
29+
steps:
30+
- uses: actions/checkout@v4
2231

23-
- name: Set up Python ${{ matrix.python-version }}
24-
uses: actions/setup-python@v5
25-
with:
26-
python-version: ${{ matrix.python-version }}
32+
- name: Set up Python ${{ matrix.python-version }}
33+
uses: actions/setup-python@v5
34+
with:
35+
python-version: ${{ matrix.python-version }}
2736

28-
- name: Run tests
29-
run: |
30-
pip install --upgrade pip
31-
pip install --upgrade tox
32-
tox -e py
37+
- name: Run tests
38+
run: |
39+
pip install --upgrade pip
40+
pip install --upgrade tox
41+
tox -e py
3342
34-
- name: Upload coverage report
35-
uses: codecov/codecov-action@v5
43+
- name: Upload coverage report
44+
uses: codecov/codecov-action@v5

.github/workflows/tests-ubuntu.yml

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,44 @@
1+
---
12
name: Ubuntu
23

34
on:
4-
push:
5-
branches:
6-
- master
7-
pull_request:
8-
branches:
9-
- master
5+
push:
6+
branches:
7+
- master
8+
pull_request:
9+
branches:
10+
- master
1011

1112
jobs:
12-
tests:
13+
tests:
14+
runs-on: ubuntu-latest
1315

14-
runs-on: ubuntu-latest
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14.0-rc.1", "pypy3.10", "pypy3.11"]
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
python-version:
20+
- '3.9'
21+
- '3.10'
22+
- '3.11'
23+
- '3.12'
24+
- '3.13'
25+
- 3.14.0-rc.1
26+
- pypy3.10
27+
- pypy3.11
1928

20-
steps:
21-
- uses: actions/checkout@v4
29+
steps:
30+
- uses: actions/checkout@v4
2231

23-
- name: Set up Python ${{ matrix.python-version }}
24-
uses: actions/setup-python@v5
25-
with:
26-
python-version: ${{ matrix.python-version }}
32+
- name: Set up Python ${{ matrix.python-version }}
33+
uses: actions/setup-python@v5
34+
with:
35+
python-version: ${{ matrix.python-version }}
2736

28-
- name: Run tests
29-
run: |
30-
pip install --upgrade pip
31-
pip install --upgrade tox
32-
tox -e py
37+
- name: Run tests
38+
run: |
39+
pip install --upgrade pip
40+
pip install --upgrade tox
41+
tox -e py
3342
34-
- name: Upload coverage report
35-
uses: codecov/codecov-action@v5
43+
- name: Upload coverage report
44+
uses: codecov/codecov-action@v5

.github/workflows/tests-windows.yml

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,44 @@
1+
---
12
name: Windows
23

34
on:
4-
push:
5-
branches:
6-
- master
7-
pull_request:
8-
branches:
9-
- master
5+
push:
6+
branches:
7+
- master
8+
pull_request:
9+
branches:
10+
- master
1011

1112
jobs:
12-
tests:
13+
tests:
14+
runs-on: windows-latest
1315

14-
runs-on: windows-latest
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14.0-rc.1"]
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
python-version:
20+
- '3.9'
21+
- '3.10'
22+
- '3.11'
23+
- '3.12'
24+
- '3.13'
25+
- 3.14.0-rc.1
26+
- pypy3.10
27+
- pypy3.11
1928

20-
steps:
21-
- uses: actions/checkout@v4
29+
steps:
30+
- uses: actions/checkout@v4
2231

23-
- name: Set up Python ${{ matrix.python-version }}
24-
uses: actions/setup-python@v5
25-
with:
26-
python-version: ${{ matrix.python-version }}
32+
- name: Set up Python ${{ matrix.python-version }}
33+
uses: actions/setup-python@v5
34+
with:
35+
python-version: ${{ matrix.python-version }}
2736

28-
- name: Run tests
29-
run: |
30-
pip install --upgrade pip
31-
pip install --upgrade tox
32-
tox -e py
37+
- name: Run tests
38+
run: |
39+
pip install --upgrade pip
40+
pip install --upgrade tox
41+
tox -e py
3342
34-
- name: Upload coverage report
35-
uses: codecov/codecov-action@v5
43+
- name: Upload coverage report
44+
uses: codecov/codecov-action@v5

0 commit comments

Comments
 (0)