Skip to content

Commit

Permalink
Add pre-commit and an initial CI
Browse files Browse the repository at this point in the history
  • Loading branch information
art049 committed Sep 12, 2022
1 parent 5c32de6 commit 94cf339
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]

jobs:
static-analysis:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: "3.9"
- uses: pre-commit/action@v2.0.0
with:
extra_args: --all-files
30 changes: 30 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/prettier/prettier
rev: 1.19.1
hooks:
- id: prettier
- repo: https://github.com/psf/black
rev: 19.3b0
hooks:
- id: black
- repo: https://github.com/timothycrosley/isort.git
rev: "4.3.21-2"
hooks:
- id: isort
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.740
hooks:
- id: mypy
- repo: https://gitlab.com/pycqa/flake8.git
rev: 8f9b4931b9a28896fb43edccb23016a7540f5b82
hooks:
- id: flake8

0 comments on commit 94cf339

Please # to comment.