Skip to content

fix(linting): use Husky 9 format for pre-commit hooks#21

Merged
markcallen merged 1 commit intomainfrom
fix/husky-hook-header
Feb 13, 2026
Merged

fix(linting): use Husky 9 format for pre-commit hooks#21
markcallen merged 1 commit intomainfrom
fix/husky-hook-header

Conversation

@markcallen
Copy link
Contributor

Summary

Updates the linting agent instructions to use the Husky 9 format for pre-commit hooks. The shebang (#!/usr/bin/env sh) and bootstrap line (. "$(dirname -- "$0")/_/husky.sh") are deprecated in Husky 9 and will fail in v10.0.0.

Changes

  • Remove deprecated header instructions from section 5 (Set Up Git Hooks with Husky)
  • Simplify pre-commit hook example to command-only: npx lint-staged
  • Update implementation order and Important Notes to reflect Husky 9 behavior
  • Add explicit note that Husky 9+ runs hooks directly without the legacy header

Remove deprecated shebang and bootstrap lines from linting agent
instructions. Husky 9+ runs hooks directly without the legacy header;
the old format is deprecated and will fail in v10.0.0.

Co-authored-by: Cursor <cursoragent@cursor.com>
Copilot AI review requested due to automatic review settings February 13, 2026 02:18
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the linting agent’s Husky guidance to align with Husky v9 behavior, avoiding the legacy hook header that no longer matches this repo’s Husky setup.

Changes:

  • Removes the deprecated “standard Husky header” instructions from the Husky setup section.
  • Updates the pre-commit hook example and guidance to be “command-only” (e.g., npx lint-staged) for Husky 9+.
  • Adjusts the implementation order and Important Notes to reflect Husky 9+ hook execution expectations.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@markcallen markcallen merged commit 54fb0ee into main Feb 13, 2026
11 checks passed
@markcallen markcallen deleted the fix/husky-hook-header branch February 13, 2026 03:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant