Skip to content

Commit 7ac9dce

Browse files
committedOct 7, 2021
Updaet main.yml
1 parent 9d5ae61 commit 7ac9dce

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed
 

‎.github/workflows/main.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
name: Publish to PyPI
22

33
on:
4-
push:
5-
branches: [master]
4+
create:
65

76
# Allows you to run this workflow manually from the Actions tab
87
workflow_dispatch:
98

109
jobs:
1110
build:
11+
if: ${{ startsWith(github.ref, 'refs/tags') }}
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Prepare repo
@@ -40,7 +40,6 @@ jobs:
4040
# repository_url: https://test.pypi.org/legacy/
4141

4242
- name: Publish distribution 📦 to PyPI
43-
if: ${{ startsWith(github.ref, 'refs/tags') }}
4443
uses: pypa/gh-action-pypi-publish@master
4544
with:
4645
password: ${{ secrets.PIP_API_TOKEN }}

0 commit comments

Comments
 (0)