Skip to content

Commit 80c70fa

Browse files
authored
Merge pull request #20 from contentauth/ok-nick/dispatch-publish
Allow publish to be manually dispatchable
2 parents af1d974 + e08c39e commit 80c70fa

File tree

2 files changed

+28
-18
lines changed

2 files changed

+28
-18
lines changed

.github/workflows/build.yml

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -141,21 +141,3 @@ jobs:
141141
with:
142142
name: wheels
143143
path: dist
144-
145-
release:
146-
name: Release
147-
runs-on: ubuntu-latest
148-
environment: Publish
149-
if: "startsWith(github.ref, 'refs/tags/')"
150-
needs: [linux, windows, macos_x86, macos_aarch64, sdist]
151-
steps:
152-
- uses: actions/download-artifact@v3
153-
with:
154-
name: wheels
155-
- name: Publish to PyPI
156-
uses: PyO3/maturin-action@v1
157-
env:
158-
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
159-
with:
160-
command: upload
161-
args: --non-interactive --skip-existing *

.github/workflows/publish.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
release:
14+
name: Release
15+
runs-on: ubuntu-latest
16+
environment: Publish
17+
needs: [linux, windows, macos_x86, macos_aarch64, sdist]
18+
steps:
19+
- uses: actions/download-artifact@v4
20+
with:
21+
name: wheels
22+
- name: Publish to PyPI
23+
uses: PyO3/maturin-action@v1
24+
env:
25+
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
26+
with:
27+
command: upload
28+
args: --non-interactive --skip-existing *

0 commit comments

Comments
 (0)