From 3694f8e6eb0f0174c57340946436ddf43b5b4fa6 Mon Sep 17 00:00:00 2001 From: tbradsha <32492176+tbradsha@users.noreply.github.com> Date: Thu, 19 Dec 2024 19:40:22 -0700 Subject: [PATCH] Migrate hooks to husky v9 --- .husky/post-checkout | 3 --- .husky/post-merge | 3 --- .husky/pre-commit | 3 --- .husky/pre-push | 3 --- package.json | 2 +- 5 files changed, 1 insertion(+), 13 deletions(-) diff --git a/.husky/post-checkout b/.husky/post-checkout index 9446120543228..2c34b3c5d7416 100755 --- a/.husky/post-checkout +++ b/.husky/post-checkout @@ -1,4 +1 @@ -#!/bin/sh -. "$(dirname "$0")/_/husky.sh" - ./tools/js-tools/git-hooks/post-merge-checkout-hook.sh "$1" diff --git a/.husky/post-merge b/.husky/post-merge index 7399d9143f1bb..1ab789ff25e76 100755 --- a/.husky/post-merge +++ b/.husky/post-merge @@ -1,4 +1 @@ -#!/bin/sh -. "$(dirname "$0")/_/husky.sh" - ./tools/js-tools/git-hooks/post-merge-checkout-hook.sh ORIG_HEAD diff --git a/.husky/pre-commit b/.husky/pre-commit index 3f41ae0243919..7530bd93a2b36 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,4 +1 @@ -#!/bin/sh -. "$(dirname "$0")/_/husky.sh" - node tools/js-tools/git-hooks/pre-commit-hook.js diff --git a/.husky/pre-push b/.husky/pre-push index 300e69f5b8f78..8b85d51a7d8ae 100755 --- a/.husky/pre-push +++ b/.husky/pre-push @@ -1,6 +1,3 @@ -#!/bin/sh -. "$(dirname "$0")/_/husky.sh" - if test -c /dev/tty && sh -c ': < /dev/tty' >/dev/null 2>/dev/null; then exec < /dev/tty fi diff --git a/package.json b/package.json index 5766b32f7695f..641c201fe11d0 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,7 @@ "php:autofix": "composer phpcs:fix", "php:compatibility": "composer phpcs:compatibility", "php:lint": "composer phpcs:lint", - "prepare": "husky install", + "prepare": "husky", "reformat-files": "prettier --ignore-path .eslintignore --write \"**/*.{js,jsx,cjs,mjs,ts,tsx,svelte,json,json5}\"", "version-packages": "bash ./tools/version-packages.sh" },