@@ -3,17 +3,41 @@ name: Link Status
33on : [push, pull_request]
44
55jobs :
6- build :
7- runs-on : ubuntu-16.04
6+ pre-commit :
7+ name : Pre-Commit Checks
8+ runs-on : ubuntu-latest
9+ steps :
10+ - name : Checkout to master
11+ uses : actions/checkout@master
12+
13+ - name : Setup python
14+ uses : actions/setup-python@v1
15+ with :
16+ python-version : ' 3.7'
17+ architecture : ' x64'
18+
19+ - name : Pre-Commit Checks
20+ run : |
21+ python -m pip install pre-commit
22+ pre-commit run -a
23+
24+ - name : Analysis (git diff)
25+ if : failure()
26+ run : git diff
27+
28+ tests :
29+ name : Test-${{ matrix.os }}-Py${{ matrix.python-version }}
30+ needs : pre-commit
31+ runs-on : ${{ matrix.os }}
832 strategy :
933 matrix :
34+ os : [ubuntu-latest, windows-latest, macos-latest]
1035 python-version : [ '3.6', '3.7' ]
11- name : Python ${{ matrix.python-version }}
1236 steps :
1337 - name : Checkout to master
1438 uses : actions/checkout@master
1539
16- - name : Setup python
40+ - name : Setup Python-${{ matrix. python-version }}
1741 uses : actions/setup-python@v1
1842 with :
1943 python-version : ${{ matrix.python-version }}
2448 python -m pip install .
2549 python -m pip install -Ur dev-requirements.txt
2650
27- - name : Pre-Commit
28- run : pre-commit run -a
29-
30- - name : Analysis (git diff)
31- if : failure()
32- run : git diff
33-
3451 - name : Unit Tests
3552 run : py.test tests -v
36-
37- - name : Build Package
38- if : matrix.python-version == '3.7' && github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
39- run : |
40- python -m pip install --upgrade setuptools wheel
41- python setup.py sdist bdist_wheel
42-
43- - name : Deploy to PyPi
44- if : github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
45- uses : pypa/gh-action-pypi-publish@master
46- with :
47- user : __token__
48- password : ${{ secrets.pypi_linkstatus }}
0 commit comments