From e245f95738c806b540cdd5d5fc87a2834b198ccb Mon Sep 17 00:00:00 2001 From: Lourival Vieira Neto Date: Thu, 26 Nov 2026 10:50:10 -0300 Subject: [PATCH] settings: a starting session lists the saved session states A session started or cleared runs harness/.claude/hooks/on-start.sh, which lists the files under scratch/handoff/ that a session past 300k tokens of context wrote before it was cleared, newest first, so the new one reads the state it continues (luainkernel/harness#14). The mount carries the hook; Claude Code reads only the project's own settings, so the project wires it. Co-Authored-By: Claude Opus 5.5 --- .claude/settings.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.claude/settings.json b/.claude/settings.json index 8617804..f55acf1 100644 --- a/.claude/settings.json +++ b/.claude/settings.json @@ -131,6 +131,15 @@ } ] }, + { + "matcher": "startup|clear", + "hooks": [ + { + "type": "command", + "command": "bash \"$CLAUDE_PROJECT_DIR/harness/.claude/hooks/on-start.sh\"" + } + ] + }, { "matcher": "compact", "hooks": [