docs: fix documentation accuracy (hook command, config keys, sidecar flags, env vars)#346
docs: fix documentation accuracy (hook command, config keys, sidecar flags, env vars)#346cursor[bot] wants to merge 3 commits into
Conversation
…ccuracy Key corrections: - CLI.md: add missing 'hook' command (disable/enable/status) renamed from 'hooks' in #334 - CLI.md: fix 'config set' keys (remove stale 'apiKey'; add 'orgID' and 'validation.sidecarImage') - CLI.md: add missing 'task config' subcommand - CLI.md: add 'init --skip-skills' and '--skip-test-suites' flags - CLI.md: remove non-existent 'sidecar setup --snapshot-name' and '--skip-snapshot' flags - CLI.md: add 'sidecar list --all' and '--json' flags - CLI.md: add 'validate --org-id', '--json', and 'config show --json' flags - CLI.md: fix 'sidecar create' docs (--org-id and --name are not required) - ARCHITECTURE.md: add hook.go entry; fix task.go note (now includes 'task config') - ARCHITECTURE.md: remove non-existent 'usererr/' package; add 'secrets/', 'session/', 'settings/' - ARCHITECTURE.md: add CHUNK_HOOKS_DISABLED and CLAUDE_WORKING_DIR to env var table - HOOKS.md: document 'chunk hook disable/enable/status' commands - GETTING_STARTED.md: add 'chunk validate --remote' to env-forwarding section - README.md: add 'chunk hook' to commands table Co-authored-by: schurchleycci <schurchleycci@users.noreply.github.com>
There was a problem hiding this comment.
Risk Assessment
Overall: Low — This is a small docs-only PR with no runtime behavior changes, but one documented env var appears unsupported by the current hook/validate implementation.
| Dimension | Finding |
|---|---|
| Blast radius | Low runtime blast radius: only README/docs changed. User-facing CLI and hook docs are affected, so inaccuracies can still mislead users/agents. Concern: docs/ARCHITECTURE.md:186 says CLAUDE_WORKING_DIR is used by validate, but the codebase only references that name in docs; generated Stop hooks run chunk validate, and validate resolves cwd/--project rather than reading CLAUDE_WORKING_DIR. |
| Test coverage | No runtime code paths changed, so no new command or acceptance tests are required. Residual gap: there is no generated-doc or Cobra consistency check, so docs drift remains possible. |
| Breaking changes | No concerns. The PR does not change command names, flags, defaults, output formats, or .chunk/ file structure. |
| Security | No concerns. No new token handling, file permissions, shell execution, external API calls, or dependencies are introduced. The .env.local forwarding docs describe existing behavior. |
| Complexity | Low complexity and easy to review. Minor docs formatting concern: docs/ARCHITECTURE.md:20-25 lost indentation for the added internal/cmd entries, so the directory tree renders incorrectly. |
Recommendation: either remove/correct the
CLAUDE_WORKING_DIRrow indocs/ARCHITECTURE.md:186, or update the generated Stop hook/validate path resolution to actually honor it. Also restore indentation ondocs/ARCHITECTURE.md:20-25. One adjacent stale-doc note:docs/ARCHITECTURE.md:164still shows the legacyapiKeyconfig field even though this PR updates the config-key guidance elsewhere.
Sent by Cursor Automation: chunk-cli risk assessment
There was a problem hiding this comment.
Required
[docs/ARCHITECTURE.md:20] Directory tree indentation is broken
The new hook.go through validate.go entries lost the │ prefix used by the surrounding internal/cmd/ children, so the rendered tree shows those files outside internal/cmd/. That makes the architecture map misleading for the layering rules this doc is meant to explain.
[docs/ARCHITECTURE.md:185] Env var usage does not match the code
CLAUDE_PROJECT_DIR is now listed as used by validate, and CLAUDE_WORKING_DIR is listed as used by validate, but chunk validate resolves the project from --project or os.Getwd(), and CLAUDE_WORKING_DIR is not referenced in Go code. Could this table be narrowed to the env vars the code actually reads, or the implementation updated if these are intended inputs?
[docs/HOOKS.md:105] Hook disabling is documented too broadly
This says hooks are skipped when CHUNK_HOOKS_DISABLED is set, and docs/CLI.md:155 similarly says hooks are disabled by the sentinel/env var. In code, generated PreToolUse hooks run the configured commands directly, while the disabled check is only in chunk validate Stop-hook handling and hook status. As written, users may expect chunk hook disable to suppress pre-commit PreToolUse commands when it does not.
[README.md:122] Sidecar setup summary still says it snapshots
The README command table still describes chunk sidecar setup as Detect env, install deps, snapshot, but the implementation now completes setup and tells users to run chunk sidecar snapshot create manually. Since this PR updates the same command table and fixes the CLI docs wording, this summary should be brought in sync too.
Sent by Cursor Automation: chunk-cli PR review
Co-authored-by: schurchleycci <schurchleycci@users.noreply.github.com>
|
@cursoragent can u resolve the merge conflicts ;-; |
|
Perfect! I've successfully resolved the merge conflicts. Here's what I did: Conflict Resolution SummaryFile with conflicts: Conflict details: The Resolution:
Changes committed and pushed: The merge commit is now live on the branch, and the PR is ready for review again. |
Resolved conflicts in docs/CLI.md by: - Keeping the more detailed description for --skip-test-suites from main - Maintaining consistent flag order (completions, test-suites, skills) Co-authored-by: Hanabel M. <hanabel1@users.noreply.github.com>
|
wow |



Summary
Weekly documentation accuracy review pass against the current codebase. Several gaps were introduced by recent PRs (#323, #329, #334, #335, #336) and pre-existing stale content.
What was outdated and what was corrected
docs/CLI.mdhookcommand (disable/enable/status) — renamed fromhooksin Rename hooks command to hook #334 and never added to the referenceconfig setkeys — removed staleapiKeykey (users should useauth set); addedorgIDandvalidation.sidecarImageproject-level keystask configsubcommand — existed in code but was omitted from the treeinit --skip-skillsand--skip-test-suites— new flags added in recent PRs, not documentedsidecar setupflags —--snapshot-nameand--skip-snapshotdo not exist in code;setupprints a hint to runsnapshot createmanually insteadsidecar createannotations —--org-idand--nameare not required (org has an interactive picker; name is auto-generated)sidecar list --alland--json,validate --org-idand--json,config show --json,sidecar current --json,sidecar snapshot get --json,task run --jsonconfig setkeys andhook disablemechanicsdocs/ARCHITECTURE.mdhook.goto thecmd/listing; updatedtask.gonote to includetask configusererr/package entry (the code lives ininternal/cmd/usererr.go)secrets/,session/,settings/CHUNK_HOOKS_DISABLEDandCLAUDE_WORKING_DIRto the environment variable tabledocs/HOOKS.mdchunk hook disable/enable/statusandCHUNK_HOOKS_DISABLEDdocs/GETTING_STARTED.mdchunk validate --remote(added in Add --env/--env-file flags to validate and sidecar setup #323 / Forward CIRCLE_TOKEN env vars to remote validate commands #336) alongsidesidecar sshandsidecar setupREADME.mdchunk hook disable|enable|statusto the commands table