Skip to content

Commit 94538db

Browse files
committed
fixed .github/workflows
1 parent ecfef98 commit 94538db

2 files changed

Lines changed: 22 additions & 10 deletions

File tree

.github/workflows/PyPI.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@ name: Publish PyPI
22

33
on:
44
push:
5-
# Sequence of patterns matched against refs/tags
65
tags:
7-
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
6+
- 'v*.*.*'
87

98
permissions: write-all
109

@@ -14,26 +13,33 @@ jobs:
1413
runs-on: ubuntu-latest
1514

1615
steps:
17-
- uses: actions/checkout@v4
16+
- uses: actions/checkout@v6
17+
1818
- name: Set up Python
19-
uses: actions/setup-python@v5
19+
uses: actions/setup-python@v6
2020
with:
2121
python-version: "3.x"
22+
2223
- name: Install pypa/build
2324
run: python3 -m pip install build --user
25+
2426
- name: get release version
2527
id: release-version
2628
run: |
2729
echo "$GITHUB_REF_NAME" | sed 's|^[a-zA-Z]\+|RELEASE_VERSION=|; s|-|_|g' >> $GITHUB_OUTPUT
30+
2831
- name: edit version in pyproject.toml
2932
run: sed -i 's|^version = .*|version = "${{ steps.release-version.outputs.RELEASE_VERSION }}"|' pyproject.toml
33+
3034
- name: Build a binary wheel and a source tarball
3135
run: python3 -m build
36+
3237
- name: Store the distribution packages
33-
uses: actions/upload-artifact@v3
38+
uses: actions/upload-artifact@v7
3439
with:
3540
name: python-package-distributions
3641
path: dist/
42+
3743
- name: Release
3844
uses: softprops/action-gh-release@v2
3945
with:
@@ -42,6 +48,7 @@ jobs:
4248
files: 'dist/*'
4349
token: ${{ secrets.GITHUB_TOKEN }}
4450

51+
4552
publish-to-pypi:
4653
name: Publish Python distribution to PyPI
4754
needs:
@@ -57,10 +64,11 @@ jobs:
5764

5865
steps:
5966
- name: Download all the dists
60-
uses: actions/download-artifact@v3
67+
uses: actions/download-artifact@v8
6168
with:
6269
name: python-package-distributions
6370
path: dist/
71+
6472
- name: Publish distribution to PyPI
6573
uses: pypa/gh-action-pypi-publish@release/v1
6674
with:

.github/workflows/TestPyPI.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,21 @@ jobs:
1111
runs-on: ubuntu-latest
1212

1313
steps:
14-
- uses: actions/checkout@v4
14+
- uses: actions/checkout@v6
15+
1516
- name: Set up Python
16-
uses: actions/setup-python@v5
17+
uses: actions/setup-python@v6
1718
with:
1819
python-version: "3.x"
20+
1921
- name: Install pypa/build
2022
run: python3 -m pip install build --user
23+
2124
- name: Build a binary wheel and a source tarball
2225
run: python3 -m build
26+
2327
- name: Store the distribution packages
24-
uses: actions/upload-artifact@v3
28+
uses: actions/upload-artifact@v7
2529
with:
2630
name: python-package-distributions
2731
path: dist/
@@ -41,7 +45,7 @@ jobs:
4145

4246
steps:
4347
- name: Download all the dists
44-
uses: actions/download-artifact@v3
48+
uses: actions/download-artifact@v8
4549
with:
4650
name: python-package-distributions
4751
path: dist/

0 commit comments

Comments
 (0)