Skip to content

Commit

Permalink
Allow commits if linter succeeds
Browse files Browse the repository at this point in the history
  • Loading branch information
bennothommo committed Aug 9, 2023
1 parent 516b640 commit 968a2f5
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm run lint
22 changes: 22 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"build:esm": "rollup -c rollup.esm.config.mjs",
"watch": "rollup -c rollup.esm.config.js -w",
"lint": "eslint --ext .js src tests",
"test": "jest"
"test": "jest",
"prepare": "husky install"
},
"author": "Ben Thomson <[email protected]>",
"homepage": "https://wintercms.com",
Expand All @@ -42,6 +43,7 @@
"eslint-config-airbnb-base": "^15.0.0",
"eslint-plugin-import": "^2.28.0",
"eslint-plugin-jest": "^27.2.3",
"husky": "^8.0.3",
"jest": "^29.6.2",
"jest-environment-jsdom": "^29.6.2",
"rollup": "^3.27.2"
Expand Down

0 comments on commit 968a2f5

Please sign in to comment.