-
Notifications
You must be signed in to change notification settings - Fork 7
52 lines (47 loc) · 1.25 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: pygenpass
on: [push, pull_request]
jobs:
pre-commit:
name: Pre-Commit Checks
runs-on: ubuntu-latest
steps:
- name: Checkout to master
uses: actions/checkout@master
- name: Setup python
uses: actions/setup-python@v1
with:
python-version: '3.8'
architecture: 'x64'
- name: Pre-Commit Checks
run: |
python -m pip install pre-commit
pre-commit run -a
- name: Analysis (git diff)
if: failure()
run: git diff
# For future use
# tests:
# name: Test-${{ matrix.os }}-Py${{ matrix.python-version }}
# needs: pre-commit
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ubuntu-latest, windows-latest, macos-latest]
# python-version: [ '3.6', '3.7' ]
# steps:
# - name: Checkout to master
# uses: actions/checkout@master
#
# - name: Setup Python-${{ matrix.python-version }}
# uses: actions/setup-python@v1
# with:
# python-version: ${{ matrix.python-version }}
# architecture: x64
#
# - name: Setup Package
# run: python -m pip install .
#
# - name: Unit Tests
# run: |
# python -m pip install pytest
# py.test -v