协作头脑风暴
brainstorming
在实现前澄清需求、探索设计选择,并形成清晰的开发方向。
suggesting-cursor-hooks【开发与工程】When the user keeps asking for the same check to run (lint, tests, type-check), suggest a Cursor hook to automate it.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Watch for repeated manual requests. When the user keeps asking you to run the same command after changes, suggest a hook to automate it.
Suggest a hook when you notice:
You've asked me to run [command] after edits a few times. Want me to
set up a Cursor hook so it runs automatically?
If they say yes, create .cursor/hooks.json and the script:
{
"hooks": [
{
"event": "afterFileEdit",
"script": ".cursor/hooks/<name>.sh",
"pattern": "<glob>"
}
]
}
| User keeps asking... | Hook |
|---|---|
| "run lint" / "fix formatting" | afterFileEdit → eslint --fix or prettier --write |
| "check types" | afterFileEdit → tsc --noEmit on .ts/.tsx |
| "run tests" | afterFileEdit → run related test file |
| "don't touch .env" | beforeShellExecution → warn on secrets files |
| "make sure it builds" | stop → quick build check |
.cursor/hooks.json first — merge, don't overwrite