feat(onboard): decide when the rules run before asking to mark complete - #465
Conversation
|
@claude /review |
|
Claude finished @theCodeDrift's task in 19m 23s —— View job Review completeReview mode: incremental — read 0 prior review thread(s) before reviewing.
AssessmentI read the full diff ( Correctness
Minor/non-blocking observations (none rise to the level of a required change)
No correctness, security, or test-adequacy issues found. Test coverage for the new |
Both minor observations are addressed in 1630aca. — AI Coding Agent |
Onboarding went from materializing rules straight to the consent-gated mark-complete question, so a project could finish with rules nothing runs. The onboard recipe now offers CI (agent ci) and a pre-commit hook (the new agent hooks topic) first, and asks mark-complete in a message of its own. detect --json reports the CI systems and commit-hook tools configured at the repository root as two additive fields, ci and hooks.
…t CI and hooks as plain blocks
1630aca to
2cde3be
Compare
The onboard recipe went from writing rules straight to the consent-gated
--mark-completequestion. Nothing asked when the new rules would run, so a project could finish onboarding with rules that never run. When an agent made up the missing question itself, it asked it in the same message as mark-complete, and the user's "yes" could have answered either one.What changes
agent ciandagent hooksand does whichever the user picks. Picking neither is fine, and the recipe says so in one line. The mark-complete question must be asked in a message with no other question in it. See Also now listsciandhooks.detect --jsongains two fields,ciandhooks, both lists of{ name, evidence }entries shaped likelinters. Nothing existing changes. Both are read at the repository root only: CI reads its config from there, and git runs one set of hooks per repository, so a match inside a sub-package is not this repo's setup.agent hookstopic (internal). It covers runningcheckon staged files in the hook tool the repo already uses (lint-staged, lefthook, pre-commit, husky, simple-git-hooks). It also covers:checkwith no paths scans the whole projecttestplus a fullcheckwhen a file under.taskless/rules/changesci(v3 → v4),check(v5 → v6),detect(v1 → v2) now point to the new field and topic. The installed skill's topic table gets ahooksrow.Where this differs from the issue's suggestions
--no-stashhas a downside, and the recipe states it. lint-staged documents that the flag implies--no-hide-partially-staged. A partially staged file is then checked as it is in the working tree, not as staged. The recipe explains the trade-off and leaves the choice to the user.checkverifies the rules with the service on every commit and runs the runtime rules that pass. The recipe says this, offers--anonymousif that is too slow, and forbids--dangerously-run-scripts.Verification
pnpm typecheckandpnpm lintpass, and the full CLI suite passes (114 files, 2035 tests).detect.test.tscovers every CI system and hook tool, root-only matching, and empty arrays.onboard.test.tscovers step order, the decline path, the question asked alone, and See Also.cli-onboard,cli-detectandcli-agentsurvives the archive, plus four new ones in each.Fixes #441