-
Notifications
You must be signed in to change notification settings - Fork 14
37 lines (36 loc) · 1.1 KB
/
format-check.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
name: Format Check
on: push
jobs:
check-formatting:
name: Code Formatting
runs-on: ubuntu-latest
steps:
- uses: JoshuaSBrown/cpp-py-formatter/[email protected]
with:
clangFormatVersion: 10
token: ${{ secrets.GITHUB_TOKEN }}
format-check:
runs-on: ubuntu-latest
if: ${{ always() }}
# needs: check-formatting
strategy:
matrix:
python-version: [ "3.9" ]
steps:
- uses: actions/checkout@v2
- name: Update ubuntu
run: sudo apt-get update
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt-get install -y python3-sphinx sphinx-rtd-theme-common
pip install sphinx_rtd_theme recommonmark flake8 black pytest pytest-cov
- name: Black formatting checks
run: black --check .
- name: Lint with flake8
run: |
flake8 --count --select=E9,F63,F7,F82 --show-source --statistics .
flake8 --count --statistics .