A local-first personal finance app
[AI] Add project-level hook to enforce PR creation rules (#7471)
Matiss Janis Aboltinsd6253c86ebe7
diff --git a/.claude/settings.json b/.claude/settings.jsonnew file mode 100644index 0000000000..9244556f46--- /dev/null+++ b/.claude/settings.json@@ -0,0 +1,17 @@+{+ "hooks": {+ "PreToolUse": [+ {+ "matcher": "Bash",+ "hooks": [+ {+ "type": "command",+ "if": "Bash(gh pr create*)",+ "command": "echo '{\"hookSpecificOutput\":{\"hookEventName\":\"PreToolUse\",\"permissionDecision\":\"ask\",\"permissionDecisionReason\":\"STOP: Read .github/agents/pr-and-commit-rules.md FIRST, then create the PR following its rules (title prefix, labels, blank template).\"}}'",+ "statusMessage": "Checking PR creation rules..."+ }+ ]+ }+ ]+ }+}diff --git a/upcoming-release-notes/7471.md b/upcoming-release-notes/7471.mdnew file mode 100644index 0000000000..d8808a8078--- /dev/null+++ b/upcoming-release-notes/7471.md@@ -0,0 +1,6 @@+---+category: Maintenance+authors: [MatissJanis]+---++AI: force Claude Code to read PR creation rules