File tree Expand file tree Collapse file tree 2 files changed +21
-11
lines changed Expand file tree Collapse file tree 2 files changed +21
-11
lines changed Original file line number Diff line number Diff line change @@ -19,10 +19,16 @@ jobs:
1919 uses : actions/setup-python@v2
2020 with :
2121 python-version : ${{ matrix.python-version }}
22+ - name : Cache pip
23+ uses : actions/cache@v2
24+ with :
25+ path : ~/.cache/pip
26+ key : ${{ runner.os }}-pip-${{ hashFiles('requirements.txt') }}
27+ restore-keys : |
28+ ${{ runner.os }}-pip-
29+ ${{ runner.os }}-
2230 - name : Install dependencies
2331 run : |
24- make init
25- make requirements
2632 pip install -r requirements-dev.txt
2733 - name : Lint
2834 run : |
Original file line number Diff line number Diff line change 1- name : CI
1+ name : Publish
22
33on :
44 release :
5- types : [created]
6- workflow_dispatch :
5+ types : [published]
76
87jobs :
98 deploy :
@@ -14,12 +13,17 @@ jobs:
1413 uses : actions/setup-python@v2
1514 with :
1615 python-version : 3.8
17- - name : Publish package
16+ - name : Install dependencies
17+ run : |
18+ python3 -m pip install -r requirements-dev.txt
19+ python3 -m pip install -U setuptools wheel twine
20+ - name : Build package
21+ run : |
22+ python3 setup.py sdist bdist_wheel
23+ - name : Publish package to PyPI
24+ run : |
25+ python3 -m twine check dist/*
26+ python3 -m twine upload dist/*
1827 env :
1928 TWINE_USERNAME : __token__
2029 TWINE_PASSWORD : ${{ secrets.PYPI_TOKEN }}
21- run : |
22- python -m pip install -U twine wheel
23- python setup.py sdist bdist_wheel
24- twine check dist/*
25- twine upload dist/*
You can’t perform that action at this time.
0 commit comments