@@ -27,14 +27,18 @@ jobs:
27
27
- name : Versions
28
28
run : |
29
29
python3 --version
30
- - uses : actions/checkout@v1
30
+ - name : Checkout Current Repo
31
+ uses : actions/checkout@v1
31
32
with :
32
33
submodules : true
34
+ - name : Checkout tools repo
35
+ uses : actions/checkout@v2
36
+ with :
37
+ repository : adafruit/actions-ci-circuitpython-libs
38
+ path : actions-ci
33
39
- name : Install deps
34
40
run : |
35
- sudo apt-get install -y gettext
36
- pip install -r requirements.txt
37
- pip install circuitpython-build-tools Sphinx sphinx-rtd-theme
41
+ source actions-ci/install.sh
38
42
- name : Build assets
39
43
run : circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --library_location .
40
44
- name : Upload Release Assets
@@ -53,15 +57,22 @@ jobs:
53
57
runs-on : ubuntu-latest
54
58
steps :
55
59
- uses : actions/checkout@v1
60
+ - name : Check For setup.py
61
+ id : need-pypi
62
+ run : |
63
+ echo ::set-output name=setup-py::$( find . -wholename './setup.py' )
56
64
- name : Set up Python
65
+ if : contains(steps.need-pypi.outputs.setup-py, 'setup.py')
57
66
uses : actions/setup-python@v1
58
67
with :
59
68
python-version : ' 3.x'
60
69
- name : Install dependencies
70
+ if : contains(steps.need-pypi.outputs.setup-py, 'setup.py')
61
71
run : |
62
72
python -m pip install --upgrade pip
63
73
pip install setuptools wheel twine
64
74
- name : Build and publish
75
+ if : contains(steps.need-pypi.outputs.setup-py, 'setup.py')
65
76
env :
66
77
TWINE_USERNAME : ${{ secrets.pypi_username }}
67
78
TWINE_PASSWORD : ${{ secrets.pypi_password }}
0 commit comments