Skip to content

Commit 2ae0a20

Browse files
authored
Merge pull request #10 from dschenck/dschenck-patch-workflow
Create publishing.yml
2 parents 8fa2dac + 5eedc54 commit 2ae0a20

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

.github/workflows/publishing.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# This workflow will upload a Python Package using Twine when a release is created
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
3+
name: Upload Python Package
4+
5+
on:
6+
release:
7+
types: [published]
8+
workflow_dispatch:
9+
10+
permissions:
11+
contents: read
12+
13+
jobs:
14+
deploy:
15+
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- uses: actions/checkout@v3
20+
- name: Set up Python
21+
uses: actions/setup-python@v3
22+
with:
23+
python-version: '3.x'
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
pip install build
28+
- name: Build package
29+
run: python -m build
30+
- name: Publish package
31+
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
32+
with:
33+
user: __token__
34+
password: ${{ secrets.PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)