Skip to content

Commit

Permalink
Add github action for black and flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
k9845 committed Mar 20, 2024
1 parent 0214b5e commit ab29736
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/black.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Black Check

on:
pull_request:
push:
branches:
- develop

jobs:
check:
name: Black Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Install black
run: pip install black
- name: Run black
uses: rickstaa/action-black@v1
with:
black_args: ". --check"
25 changes: 25 additions & 0 deletions .github/workflows/flake8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Flake8 check.

on:
pull_request:
push:
branches:
- develop

jobs:
check:
name: Flake8 check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

# Flake8 check
- name: Install flake8
run: pip install flake8
- name: Run flake8
uses: suo/flake8-github-action@releases/v1
with:
# NOTE: this needs to be the same as the job name
checkName: 'Flake8 check'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit ab29736

Please sign in to comment.