From b3bd7d4d6b6f7a01a2f302954c4441d15cbe380e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Sep 2021 15:39:21 +0800 Subject: [PATCH] chore: bump husky from 4.3.8 to 7.0.2 (#4763) --- .husky/pre-commit | 4 ++++ package.json | 10 +++------- 2 files changed, 7 insertions(+), 7 deletions(-) create mode 100755 .husky/pre-commit diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100755 index 0000000000..36af219892 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,4 @@ +#!/bin/sh +. "$(dirname "$0")/_/husky.sh" + +npx lint-staged diff --git a/package.json b/package.json index 2d1f32a234..5815b63e04 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,8 @@ "scripts": { "eslint": "eslint .", "test": "mocha test/index.js", - "test-cov": "nyc --reporter=lcovonly npm test -- --no-parallel" + "test-cov": "nyc --reporter=lcovonly npm test -- --no-parallel", + "prepare": "husky install" }, "directories": { "lib": "./lib", @@ -70,7 +71,7 @@ "eslint": "^7.0.0", "eslint-config-hexo": "^4.1.0", "hexo-renderer-marked": "^4.0.0", - "husky": "^4.2.5", + "husky": "^7.0.2", "lint-staged": "^11.0.0", "mocha": "^9.1.1", "nyc": "^15.0.0", @@ -78,10 +79,5 @@ }, "engines": { "node": ">=12.13.0" - }, - "husky": { - "hooks": { - "pre-commit": "lint-staged" - } } }