Skip to content

Commit

Permalink
Add GitHub Action for flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
Ash-2k3 committed May 10, 2024
1 parent 341b780 commit f3be4b9
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/flake8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Flake8 Workflow

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.7
uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
pyhton3 -m pip install flake8;
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics

0 comments on commit f3be4b9

Please sign in to comment.