Add SessionStart continuation-digest hook#7
Conversation
Future sessions get a concise 'where we are / how to continue' digest
injected at start: git state (live), the Linear-ledger + issue-first
flow, known next actions (Linear MCP re-auth, backlog), and the
guardrails/determinism reminders. Script .claude/hooks/session-context.sh
(self-updating git bits), wired via .claude/settings.json
hooks.SessionStart. Permissions block unchanged.
Evidence: settings.json valid JSON; jq confirms hook command + 36 allow
/15 deny preserved; pipe-test (echo '{}' | hook) prints digest, exit 0.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4caa4d8098
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Addresses Codex P2 on PR #7: the relative '.claude/hooks/...' command resolved against the session launch CWD, so a session started from a subdir (e.g. src/) would fail to find the hook and silently skip the digest. Now invokes via ${CLAUDE_PROJECT_DIR:-.} (absolute project root Claude Code provides to hooks; '.' fallback). Verified: runs from src/ with CLAUDE_PROJECT_DIR set, and from root with it unset.
|
@codex addressed the P2 ("Make the hook path independent of the launch directory") in 6f0b2b8: the SessionStart command now invokes |
|
Codex Review: Didn't find any major issues. Bravo. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Lets a future session resume this work without re-deriving state (this session got long).
Change
.claude/hooks/session-context.sh— prints a digest: live git state, Linear-ledger + issue-first flow, known next actions (Linear MCP/mcpre-auth + restart; open backlog VOI-29/32/33), and guardrails/determinism reminders..claude/settings.json—hooks.SessionStartruns it. Permissions block untouched (36 allow / 15 deny preserved).Evidence
settings.jsonvalid JSON;jq -econfirms the hook command and preserved permissions countsecho '{}' | bash .claude/hooks/session-context.shprints the digest, exit 0/hooksto reviewTracking
No Linear issue linked — the Linear MCP is mid-reauth after the VOI-27
/sse→/mcpmigration (tools unavailable this session). To be backfilled as a Linear issue once re-authed (the digest itself flags this).