Skip to content

Extract inline hooks to dedicated files and add hook documentation #46

@PAMulligan

Description

@PAMulligan

Summary

7 of 8 hooks are defined as inline bash commands in .claude/settings.json. Only regression-reminder.sh exists as a dedicated file. This makes hooks hard to test, maintain, and understand.

Current State

Hook Location Issue
Post-build QA reminder inline in settings.json Untestable
Pre-commit token guard inline in settings.json Untestable
Dark mode reminder inline in settings.json Untestable
Coverage enforcement inline in settings.json Untestable
Lighthouse CI inline in settings.json Untestable
Bundle size guard inline in settings.json Untestable
Mutation testing reminder inline in settings.json Untestable
Regression reminder .claude/hooks/regression-reminder.sh OK

Additional Gaps

  • No user-facing documentation explaining the hook system
  • No guide for creating custom hooks
  • No error handling in existing hooks
  • Hook execution order is undefined

Acceptance Criteria

  • Each hook extracted to its own file in .claude/hooks/
  • settings.json updated to reference external files
  • Each hook file has error handling (exit gracefully on failure)
  • Documentation page explaining hook system, execution order, and how to create custom hooks
  • Hooks are testable in isolation

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions