File tree Expand file tree Collapse file tree 1 file changed +23
-35
lines changed Expand file tree Collapse file tree 1 file changed +23
-35
lines changed Original file line number Diff line number Diff line change 5
5
push :
6
6
branches :
7
7
- master
8
-
9
-
10
8
jobs :
11
- build-n-publish :
12
- name : Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI
13
- runs-on : ubuntu-18.04
14
-
15
-
9
+ deploy :
10
+ runs-on : ubuntu-20.04
11
+
16
12
steps :
17
- - uses : actions/checkout@master
18
- - name : Set up Python 3.9
19
- uses : actions/setup-python@v1
20
- with :
21
- python-version : 3.9
22
-
23
- - name : Install pypa/build
13
+ - uses : actions/checkout@v2
14
+ - uses : actions/setup-python@v2
15
+ - name : Install dependencies
16
+ run : |
17
+ python -m pip install --upgrade pip
18
+ pip install setuptools wheel twine
19
+ - name : Build and publish on testpypi
24
20
working-directory : ./lib
25
-
26
- run : >-
27
- python -m
28
- pip install
29
- build
30
- --user
31
- - name : Build a binary wheel and a source tarball
21
+ env :
22
+ TWINE_USERNAME : __token__
23
+ TWINE_PASSWORD : ${{ secrets.TEST_PYPI_API_TOKEN }}
24
+ run : |
25
+ python setup.py sdist bdist_wheel
26
+ twine upload testpypi dist/*
27
+ - name : Build and publish
32
28
working-directory : ./lib
33
-
34
- run : >-
35
- python -m
36
- build
37
- --sdist
38
- --wheel
39
- --outdir dist/
40
- .
41
-
42
- - name : Publish distribution 📦 to PyPI
43
- uses : pypa/gh-action-pypi-publish@master
44
- with :
45
- password : ${{ secrets.PYPI_API_TOKEN }}
46
-
29
+ env :
30
+ TWINE_USERNAME : __token__
31
+ TWINE_PASSWORD : ${{ secrets.PYPI_API_TOKEN }}
32
+ run : |
33
+ python setup.py sdist bdist_wheel
34
+ twine upload dist/*
47
35
You can’t perform that action at this time.
0 commit comments