diff --git a/sh/husky.sh b/sh/husky.sh index aabf9fe76..76671e926 100644 --- a/sh/husky.sh +++ b/sh/husky.sh @@ -58,7 +58,7 @@ debug "Current working directory is $(pwd)" # Don't skip if .huskyrc.js or .huskyrc.config.js are used as the heuristic could # fail due to the dynamic aspect of JS. For example: # `"pre-" + "commit"` or `require('./config/hooks')`) -if [ ! -f .huskyrc.js ] && [ ! -f .huskyrc.config.js ] && ! hookIsDefined; then +if [ ! -f .huskyrc.js ] && [ ! -f husky.config.js ] && ! hookIsDefined; then debug "$hookName config not found, skipping hook" exit 0 fi diff --git a/src/installer/__tests__/__snapshots__/scripts.ts.snap b/src/installer/__tests__/__snapshots__/scripts.ts.snap index a8f1bb3fb..400d31178 100644 --- a/src/installer/__tests__/__snapshots__/scripts.ts.snap +++ b/src/installer/__tests__/__snapshots__/scripts.ts.snap @@ -87,7 +87,7 @@ debug \\"Current working directory is $(pwd)\\" # Don't skip if .huskyrc.js or .huskyrc.config.js are used as the heuristic could # fail due to the dynamic aspect of JS. For example: # \`\\"pre-\\" + \\"commit\\"\` or \`require('./config/hooks')\`) -if [ ! -f .huskyrc.js ] && [ ! -f .huskyrc.config.js ] && ! hookIsDefined; then +if [ ! -f .huskyrc.js ] && [ ! -f husky.config.js ] && ! hookIsDefined; then debug \\"$hookName config not found, skipping hook\\" exit 0 fi