ci: Migrate husky from v4 to v5

This commit is contained in:
peaceiris 2021-02-09 19:30:33 +09:00
parent da35efefa8
commit 9564982d19
No known key found for this signature in database
GPG key ID: 5868468A8EBA64EC
3 changed files with 4 additions and 9 deletions

2
.husky/post-merge Normal file
View file

@ -0,0 +1,2 @@
(git diff 'HEAD@{1}' --name-only | grep 'package-lock.json' > /dev/null) && npm ci || :
git remote prune origin

1
.husky/pre-commit Normal file
View file

@ -0,0 +1 @@
npx lint-staged

View file

@ -16,15 +16,7 @@
"tsc": "tsc",
"format": "prettier --write **/*.ts",
"format:check": "prettier --check **/*.ts",
"release": "standard-version",
"update-deps": "(git diff 'HEAD@{1}' --name-only | grep 'package-lock.json' > /dev/null) && npm ci || :"
},
"husky": {
"skipCI": true,
"hooks": {
"pre-commit": "lint-staged",
"post-merge": "npm run update-deps; git remote prune origin"
}
"release": "standard-version"
},
"lint-staged": {
"{src,__tests__}/**/*.ts": [