Skip to content

Commit

Permalink
Merge pull request #2 from linkml/pypi-publish
Browse files Browse the repository at this point in the history
Using trusted publishers.
  • Loading branch information
cmungall authored Feb 1, 2024
2 parents c053e70 + 6b1bf9b commit 37f5e93
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions .github/workflows/pypi-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,33 +4,33 @@ on:
workflow_dispatch:
release:
types: [created]

jobs:
build-n-publish:
name: Build and publish Python 🐍 distributions 📦 to PyPI
runs-on: ubuntu-latest

# needs: [test]
environment: release
permissions:
id-token: write
steps:
- uses: actions/checkout@v3.0.2
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v3.1.2
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: pip
cache-dependency-path: '**/pyproject.toml'

- name: Install Poetry
run: pip install poetry poetry-dynamic-versioning

- name: Install dependencies
run: poetry install --no-interaction

- name: Build source and wheel archives
run: poetry build

- name: Publish distribution 📦 to PyPI
uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.PYPI_TOKEN }}


- name: Publish
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit 37f5e93

Please sign in to comment.