diff options
-rw-r--r-- | .pre-commit-config.yaml | 15 | ||||
-rw-r--r-- | Pipfile | 2 | ||||
-rwxr-xr-x | scripts/dev.sh | 1 |
3 files changed, 17 insertions, 1 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b7cf9ee..33921bd 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,4 +1,19 @@ repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v3.4.0 + hooks: + - id: check-merge-conflict + - id: check-toml + - id: check-yaml + - id: end-of-file-fixer + - id: mixed-line-ending + args: [--fix=lf] + - id: trailing-whitespace + args: [--markdown-linebreak-ext=md] + - repo: https://github.com/pre-commit/pygrep-hooks + rev: v1.6.0 + hooks: + - id: python-check-blanket-noqa - repo: local hooks: - id: flake8 @@ -29,7 +29,7 @@ pydocstyle = "~= 5.1" python_version = "3.9" [scripts] -lint = "flake8" +lint = "pre-commit run --all-files" precommit = "pre-commit install" test = "sh scripts/dev.sh -c 'pipenv run coverage run -m unittest'" testb = """ diff --git a/scripts/dev.sh b/scripts/dev.sh index f9cd28e..3f94874 100755 --- a/scripts/dev.sh +++ b/scripts/dev.sh @@ -24,6 +24,7 @@ if [ "$1" = "--build" ]; then if [ -n "${dangling_imgs}" ]; then printf "Removing dangling images..." + # shellcheck disable=SC2086 docker rmi $dangling_imgs >/dev/null \ && printf " done!\n" || exit "$?" fi |