From 36a4c901a8efdc67ca24b5050b6abd9bf14df51c Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Sat, 23 Jun 2018 20:54:24 +0200 Subject: [PATCH] Adding pre-commit hooks --- .pre-commit-config.yaml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .pre-commit-config.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..b789dfb --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,28 @@ +repos: +- repo: git://github.com/pre-commit/pre-commit-hooks + rev: v1.3.0 + hooks: + - id: trailing-whitespace + - id: flake8 + - id: check-yaml + - id: check-added-large-files + - id: debug-statements + - id: end-of-file-fixer +- repo: https://github.com/asottile/reorder_python_imports + rev: v1.0.1 + hooks: + - id: reorder-python-imports +- repo: local + hooks: + - id: frontend-prettify + name: Prettier Linting of JS and Vue files + description: This hook rewrites JS and the JS portion of Vue files to conform to prettier standards. + entry: yarn run lint-js -- -w + language: system + files: \.(js|vue)$ + - id: frontend-eslint + name: ESLinting of JS and Vue files + description: This hook rewrites JS and the JS portion of Vue files to conform to our ESLint standards. + entry: node node_modules/eslint/bin/eslint.js + language: system + files: \.(js|vue)$