Skip to content

Commit 9ad9394

Browse files
committed
Upgrade GitHub Actions workflows
1 parent e96e22a commit 9ad9394

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

.github/workflows/publish.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ jobs:
1212
runs-on: ubuntu-latest
1313
strategy:
1414
matrix:
15-
python-version: ["3.8", "3.9", "3.10", "3.11"]
15+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1616
steps:
17-
- uses: actions/checkout@v3
17+
- uses: actions/checkout@v4
1818
- name: Set up Python ${{ matrix.python-version }}
19-
uses: actions/setup-python@v4
19+
uses: actions/setup-python@v5
2020
with:
2121
python-version: ${{ matrix.python-version }}
2222
cache: pip
@@ -30,22 +30,22 @@ jobs:
3030
deploy:
3131
runs-on: ubuntu-latest
3232
needs: [test]
33+
environment: release
34+
permissions:
35+
id-token: write
3336
steps:
34-
- uses: actions/checkout@v3
37+
- uses: actions/checkout@v4
3538
- name: Set up Python
36-
uses: actions/setup-python@v4
39+
uses: actions/setup-python@v5
3740
with:
38-
python-version: "3.11"
41+
python-version: "3.12"
3942
cache: pip
4043
cache-dependency-path: setup.py
4144
- name: Install dependencies
4245
run: |
43-
pip install setuptools wheel twine build
44-
- name: Publish
45-
env:
46-
TWINE_USERNAME: __token__
47-
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
46+
pip install setuptools wheel build
47+
- name: Build
4848
run: |
4949
python -m build
50-
twine upload dist/*
51-
50+
- name: Publish
51+
uses: pypa/gh-action-pypi-publish@release/v1

.github/workflows/test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ jobs:
1212
matrix:
1313
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1414
steps:
15-
- uses: actions/checkout@v3
15+
- uses: actions/checkout@v4
1616
- name: Set up Python ${{ matrix.python-version }}
17-
uses: actions/setup-python@v4
17+
uses: actions/setup-python@v5
1818
with:
1919
python-version: ${{ matrix.python-version }}
2020
cache: pip

0 commit comments

Comments
 (0)