File tree Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Original file line number Diff line number Diff line change 7
7
pull_request :
8
8
branches : [ "main", "v*" ]
9
9
workflow_dispatch :
10
+ inputs :
11
+ tag :
12
+ description : tag to build
13
+ required : false
14
+ type : string
10
15
workflow_call :
16
+ inputs :
17
+ tag :
18
+ description : tag to build
19
+ required : true
20
+ type : string
11
21
12
22
permissions :
13
23
contents : read
35
45
- " pypy-3.9"
36
46
steps :
37
47
- uses : " actions/checkout@v3"
48
+ with :
49
+ ref : ${{ inputs.tag || github.ref }}
38
50
- uses : " actions/setup-python@v4"
39
51
with :
40
52
python-version : " ${{ matrix.python-version }}"
52
64
needs : tests
53
65
steps :
54
66
- uses : " actions/checkout@v3"
67
+ with :
68
+ ref : ${{ inputs.tag || github.ref }}
55
69
- uses : " actions/setup-python@v4"
56
70
with :
57
71
python-version : " 3.10"
Original file line number Diff line number Diff line change 23
23
jobs :
24
24
tests :
25
25
uses : ./.github/workflows/main.yml
26
+ with :
27
+ tag : ${{ inputs.tag }}
26
28
pypi :
27
29
name : Build and upload to PyPI
28
30
runs-on : ubuntu-latest
31
33
- name : Checkout
32
34
uses : actions/checkout@v3
33
35
with :
34
- ref : ${{ inputs.tag || github.ref }}
36
+ ref : ${{ inputs.tag }}
35
37
- name : Set up Python 3.10
36
38
uses : actions/setup-python@v4
37
39
with :
@@ -45,13 +47,13 @@ jobs:
45
47
- name : " Run twine check"
46
48
run : " python -m twine check dist/*"
47
49
- name : Publish distribution to Test PyPI
48
- uses : pypa/gh-action-pypi-publish@master
50
+ uses : pypa/gh-action-pypi-publish@release/v1
49
51
with :
50
52
password : ${{ secrets.TEST_PYPI_API_TOKEN }}
51
53
repository_url : https://test.pypi.org/legacy/
52
54
if : inputs.testpypi || false
53
55
- name : Publish distribution to PyPI
54
- uses : pypa/gh-action-pypi-publish@master
56
+ uses : pypa/gh-action-pypi-publish@release/v1
55
57
with :
56
58
password : ${{ secrets.PYPI_API_TOKEN }}
57
59
if : inputs.pypi || false
You can’t perform that action at this time.
0 commit comments