Skip to content

Commit b0174b8

Browse files
committed
update cI
1 parent 8948e2a commit b0174b8

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

.github/workflows/pypi.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
name: Publish to PyPI
22
on:
3+
workflow_dispatch:
34
push:
45
tags:
56
- '*'
67

78
jobs:
89
build-n-publish:
910
name: Build and publish to PyPI and TestPyPI
10-
runs-on: ubuntu-18.04
11+
runs-on: ubuntu-20.04
1112
steps:
12-
- uses: actions/checkout@master
13-
- name: Set up Python 3.7
14-
uses: actions/setup-python@v1
13+
- uses: actions/checkout@main
14+
- name: Set up Python 3.8
15+
uses: actions/setup-python@v2
1516
with:
16-
python-version: 3.7
17+
python-version: 3.8
1718

1819
- name: Install package
1920
run: |
@@ -25,14 +26,14 @@ jobs:
2526
python setup.py sdist
2627
2728
- name: Publish distribution to Test PyPI
28-
uses: pypa/gh-action-pypi-publish@master
29+
uses: pypa/gh-action-pypi-publish@release/v1
2930
with:
3031
user: __token__
3132
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
3233
repository_url: https://test.pypi.org/legacy/
3334
- name: Publish distribution to PyPI
3435
if: startsWith(github.ref, 'refs/tags')
35-
uses: pypa/gh-action-pypi-publish@master
36+
uses: pypa/gh-action-pypi-publish@release/v1
3637
with:
3738
user: __token__
3839
password: ${{ secrets.PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)