Skip to content

Commit 6b1618d

Browse files
authored
Update and rename python-publish.yml to publish.yml
1 parent c830b9c commit 6b1618d

File tree

2 files changed

+53
-70
lines changed

2 files changed

+53
-70
lines changed

.github/workflows/publish.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: Publish
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
permissions:
8+
contents: read
9+
10+
jobs:
11+
release-build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.10"
20+
21+
- name: Build release distributions
22+
run: |
23+
python -m pip install --upgrade pip
24+
python -m pip install build
25+
python -m build
26+
27+
- name: Upload distributions
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: release-dists
31+
path: dist/
32+
33+
pypi-publish:
34+
runs-on: ubuntu-latest
35+
needs:
36+
- release-build
37+
38+
permissions:
39+
id-token: write
40+
41+
environment:
42+
name: release
43+
url: https://pypi.org/project/grace-framework/${{ github.event.release.tag_name }}
44+
45+
steps:
46+
- name: Retrieve release distributions
47+
uses: actions/download-artifact@v4
48+
with:
49+
name: release-dists
50+
path: dist/
51+
52+
- name: Publish release distributions to PyPI
53+
uses: pypa/gh-action-pypi-publish@release/v1

.github/workflows/python-publish.yml

Lines changed: 0 additions & 70 deletions
This file was deleted.

0 commit comments

Comments
 (0)