test(vcs): Add a VCS commit hook to run linters

This commit is contained in:
Ross Patterson 2020-09-27 09:30:06 -07:00
parent b306475370
commit 5da9b8c398
2 changed files with 8 additions and 3 deletions

View File

@ -1,8 +1,15 @@
repos:
- repo: local
hooks:
- id: codechecks
name: codechecks
stages: ["commit"]
entry: "tox -e codechecks"
language: system
pass_filenames: false
- id: test
name: test
stages: ["push"]
entry: "make test"
language: system
pass_filenames: false

View File

@ -31,9 +31,7 @@ default:
.PHONY: build
## Set up and build for local development
# To also run checks on every commit:
# $ make .git/hooks/pre-commit
build: .tox .git/hooks/pre-push
build: .tox .git/hooks/pre-commit .git/hooks/pre-push
.PHONY: test
## Run all tests and code reports