aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Joe Banks <[email protected]>2020-08-24 23:18:22 +0100
committerGravatar GitHub <[email protected]>2020-08-24 23:18:22 +0100
commitcb6f16b164a19e6b2eb2b73a396e0ef75bfe07eb (patch)
treee7097609704eed6a3e9650946b83e78a5f0eb184
parentAdd basic project files (diff)
Create lint.yml
-rw-r--r--.github/workflows/lint.yml28
1 files changed, 28 insertions, 0 deletions
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
new file mode 100644
index 0000000..39846ae
--- /dev/null
+++ b/.github/workflows/lint.yml
@@ -0,0 +1,28 @@
+name: Lint Python code
+
+on:
+ push:
+ branches: [ master ]
+ pull_request:
+ branches: [ master ]
+
+jobs:
+ lint:
+ name: "Lint code"
+ # The type of runner that the job will run on
+ runs-on: ubuntu-latest
+
+ # Steps represent a sequence of tasks that will be executed as part of the job
+ steps:
+ # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
+ - name: Checkout branch
+ uses: actions/checkout@v2
+
+ - name: Install Poetry and project dependencies
+ uses: knowsuchagency/poetry-install@v2
+
+ - name: Setup flake8 annotations
+ uses: rbialon/flake8-annotations@v1
+
+ - name: Lint code with Flake8
+ run: poetry run flake8 . --count --show-source --statistics