docs(forge): add a 'which read verb when' selection table
Part of the #1802 hive-forge audit: the read verbs (view / issue / pr / comments / comment-show / timeline / diff / pr-status / pr-reviews) look overlapping but each has a distinct output shape. Add a selection table + rule-of-thumb so agents pick the right one (esp. 'view first' to clear the read-before-comment guard) instead of guessing. Zero blast radius — pure docs, no verb changes (the audit concluded the CLI is structurally clean and renames/removals aren't worth the caller breakage).
This commit is contained in:
parent
c6639fe093
commit
6a25898bfe
1 changed files with 21 additions and 0 deletions
|
|
@ -86,6 +86,27 @@ hive-forge -r internal/knowledge clone # clone with creds auto-injected
|
|||
hive-forge -r internal/knowledge pr-create --agit --topic foo --title "..." # open PR via AGit (no fork)
|
||||
```
|
||||
|
||||
### Which read verb when
|
||||
|
||||
Several verbs read an issue/PR and look overlapping, but each has a
|
||||
distinct output shape — pick by what you need:
|
||||
|
||||
| Need | Verb | Shape |
|
||||
|------|------|-------|
|
||||
| The full human view of one item — title, body, **and** every comment in order | `view <n>` | prose dump; **marks the thread read** (clears the read-before-comment guard) |
|
||||
| Just the structured metadata of one item (state, labels, assignees, head sha…) | `issue <n>` / `pr <n>` | JSON object |
|
||||
| Only the comments (skip the body), e.g. to catch up a long thread | `comments <n>` [`--tail N`] | comment list; **marks read** |
|
||||
| One specific comment by its id | `comment-show <id>` | single comment |
|
||||
| The audit trail — closes, label/assignee changes, commit refs, merges (no comment bodies) | `timeline <n>` | event list |
|
||||
| The code change | `diff <n>` | unified diff |
|
||||
| Is this PR ready to merge — mergeable + CI + reviews | `pr-status --pr <n>` | health view; exit code = merge-readiness |
|
||||
| The review verdicts + inline review comments | `pr-reviews <n>` | review list |
|
||||
|
||||
Rule of thumb: **`view` first** when you're about to act on a thread (it
|
||||
shows everything and clears the unread guard so your follow-up `comment`
|
||||
isn't rejected); the JSON verbs (`issue`/`pr`) when a script needs one
|
||||
field; `pr-status` when the only question is "can I merge it".
|
||||
|
||||
### Contributing to a read-only repo (`clone` + `pr-create --agit`)
|
||||
|
||||
Agents are read-only collaborators on some repos (e.g.
|
||||
|
|
|
|||
Loading…
Reference in a new issue