diff --git a/.husky/pre-commit b/.husky/pre-commit old mode 100644 new mode 100755 index 9ad483a5..3199e8e0 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,4 +1,4 @@ #!/bin/sh . "$(dirname "$0")/_/husky.sh" -pretty-quick --staged +npm run lint:staged diff --git a/package.json b/package.json index 35816029..d965385a 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "lint:prettier": "prettier --write **/*.{js,css,json,md,yml}", "lint:js": "eslint js/**/*.js modules/default/**/*.js clientonly/*.js serveronly/*.js translations/*.js vendor/*.js tests/**/*.js config/* --config .eslintrc.json --fix", "lint:css": "stylelint css/main.css modules/default/**/*.css --config .stylelintrc.json --fix", + "lint:staged": "pretty-quick --staged", "prepare": "[ -f node_modules/.bin/husky ] && husky install || echo no husky installed." }, "repository": {