Skip to content

Commit

Permalink
Merge pull request #237 from pyiron/trusted_publisher
Browse files Browse the repository at this point in the history
Use trusted publisher action
  • Loading branch information
jan-janssen authored Nov 17, 2023
2 parents 5d1fb9c + fc02656 commit 120b60a
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,27 @@
# This workflow is used to upload and deploy a new release to PyPi
# Based on https://github.com/pypa/gh-action-pypi-publish

name: PyPi Release

on:
push:
pull_request:
workflow_dispatch:

# based on https://github.com/pypa/gh-action-pypi-publish
jobs:
build:
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release'
runs-on: ubuntu-latest

environment:
name: pypi
url: https://pypi.org/p/pysqa
permissions:
id-token: write
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: "3.10"
python-version: "3.11"

- name: Install dependencies
run: >-
Expand All @@ -25,8 +33,4 @@ jobs:
run: >-
python setup.py sdist bdist_wheel
- name: Publish distribution 📦 to PyPI
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release'
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_password }}
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit 120b60a

Please sign in to comment.