From bccd4aeca9805387b6d806e6f5cb5ef8456f48d3 Mon Sep 17 00:00:00 2001 From: Rick Marron Date: Tue, 3 May 2022 19:36:58 -0700 Subject: [PATCH] chore(ci): migrate husky from v4->v7 (#9633) * chore(ci): migrate husky from v4->v7 * add new line --- .husky/pre-commit | 4 ++++ package.json | 8 ++------ 2 files changed, 6 insertions(+), 6 deletions(-) create mode 100755 .husky/pre-commit diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100755 index 00000000000..d2ae35e84b0 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,4 @@ +#!/bin/sh +. "$(dirname "$0")/_/husky.sh" + +yarn lint-staged diff --git a/package.json b/package.json index 6537b2d0ea1..83d3ce9ceb7 100644 --- a/package.json +++ b/package.json @@ -56,7 +56,8 @@ "arm64:services:stop": "docker-compose -f docker-compose.arm64.yml down", "arm64:services:clean": "docker-compose -f docker-compose.arm64.yml rm -v zookeeper kafka clickhouse", "dev:migrate:postgres": "export DEBUG=1 && source env/bin/activate && python manage.py migrate", - "dev:migrate:clickhouse": "export DEBUG=1 && source env/bin/activate && python manage.py migrate_clickhouse" + "dev:migrate:clickhouse": "export DEBUG=1 && source env/bin/activate && python manage.py migrate_clickhouse", + "prepare": "husky install" }, "dependencies": { "@babel/core": "^7.10.4", @@ -210,11 +211,6 @@ "optionalDependencies": { "fsevents": "^2.1.2" }, - "husky": { - "hooks": { - "pre-commit": "lint-staged" - } - }, "lint-staged": { "*.{js,jsx,mjs,ts,tsx,json,yaml,yml,css,scss}": "prettier --write", "(frontend/**).{js,jsx,mjs,ts,tsx}": "eslint -c .eslintrc.js --fix",