Skip to content

Commit 37f5e93

Browse files
authored
Merge pull request #2 from linkml/pypi-publish
Using trusted publishers.
2 parents c053e70 + 6b1bf9b commit 37f5e93

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

.github/workflows/pypi-publish.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,33 +4,33 @@ on:
44
workflow_dispatch:
55
release:
66
types: [created]
7-
7+
88
jobs:
99
build-n-publish:
1010
name: Build and publish Python 🐍 distributions 📦 to PyPI
1111
runs-on: ubuntu-latest
12-
12+
# needs: [test]
13+
environment: release
14+
permissions:
15+
id-token: write
1316
steps:
14-
- uses: actions/checkout@v3.0.2
17+
- uses: actions/checkout@v4
1518

1619
- name: Set up Python
17-
uses: actions/setup-python@v3.1.2
20+
uses: actions/setup-python@v5
1821
with:
1922
python-version: 3.9
23+
cache: pip
24+
cache-dependency-path: '**/pyproject.toml'
2025

2126
- name: Install Poetry
2227
run: pip install poetry poetry-dynamic-versioning
23-
28+
2429
- name: Install dependencies
2530
run: poetry install --no-interaction
2631

2732
- name: Build source and wheel archives
2833
run: poetry build
2934

30-
- name: Publish distribution 📦 to PyPI
31-
uses: pypa/[email protected]
32-
with:
33-
user: __token__
34-
password: ${{ secrets.PYPI_TOKEN }}
35-
36-
35+
- name: Publish
36+
uses: pypa/gh-action-pypi-publish@release/v1

0 commit comments

Comments
 (0)