Conversation
Greptile SummaryThis PR flips
Confidence Score: 5/5Safe to merge — change is additive, consistently implemented across CLI, bridge, docs, and tests, with only a minor test-reliability note. All remaining feedback is P2 (style / test quality). The core behavioral change is correctly implemented in both the CLI parser and the session bridge hook, the internal reveal field is always a concrete boolean before it reaches the bridge, and the new integration test exercises both the default and --focus paths end-to-end. No correctness, data-integrity, or security issues were found. test/session-cli.test.ts — the synchronous unchanged context check could be strengthened with a waitUntil guard, but does not affect production behavior. Important Files Changed
Sequence DiagramsequenceDiagram
participant Agent as Agent / CLI
participant CLI as cli.ts parser
participant Bridge as useHunkSessionBridge
participant UI as Session UI
Agent->>CLI: hunk session comment add --file F --new-line N --summary S
Note over CLI: focus flag absent → reveal = false
CLI->>Bridge: { action: "comment-add", reveal: false }
Bridge->>UI: setLiveCommentsByFileId(...)
Note over Bridge: reveal ?? false → skip jumpToFile / openAgentNotes
Bridge-->>Agent: { commentId, filePath, hunkIndex }
Note over UI: Viewport unchanged
Agent->>CLI: hunk session comment add ... --focus
Note over CLI: focus flag present → reveal = true
CLI->>Bridge: { action: "comment-add", reveal: true }
Bridge->>UI: setLiveCommentsByFileId(...)
Bridge->>UI: jumpToFile(fileId, hunkIndex)
Bridge->>UI: openAgentNotes()
Bridge-->>Agent: { commentId, filePath, hunkIndex }
Note over UI: Viewport jumps to new note
Reviews (1): Last reviewed commit: "Make session comment focus opt-in" | Re-trigger Greptile |
Summary
hunk session comment addleave the current viewport alone by default--no-revealwith explicit--focushelp/docs and parser coverage--focuschanges selection and opens notesTesting