Files
claude-foundations/memory/log/2026-10-26.003911.md

2.6 KiB

Session Log -- 2026-10-26

Summary

Added a folder browser, unique-topic prompt and Location column to the claude-sessions menu, then added a --headless spawn mode and moved the /spawn-session skill onto it. Tested live by spawning a "Migration" session.

Decisions

  • Decision: Folder picker uses zenity when a display exists, otherwise a built-in terminal browser -- Rationale: sessions are often driven over SSH/tmux where no GUI is available; both support creating a folder.
  • Decision: Topic = tmux session name = Remote Control name, defaulting to the Title-Cased folder name; "in use" means a live tmux session only -- Rationale: resumable registry entries do not occupy a tmux name.
  • Decision: Headless mode fails (exit 2) on a taken topic instead of adding #N -- Rationale: callers (the skill) must ask the user for a real topic so all sessions have meaningful names.
  • Decision: --create only accepts absolute paths -- Rationale: avoids creating folders in an unexpected cwd.

Gotchas Discovered

  • [editing] Symptom: a Python patch script replaced the wrong region of claude-sessions and deleted ~450 lines -- Fix: git checkout the file and re-apply with the Edit tool. Cause: s.index('elif raw == "n":') matched the first occurrence, which was inside newly inserted helper code, not cmd_menu. Anchor slice searches after a unique function marker (s.index(..., s.index("def cmd_menu"))).
  • [tmux] Symptom: tmux capture-pane -t "=Name" returns "can't find pane" -- Fix: use the bare session name for pane targets; = exact-match works only for session targets (has-session, attach, switch-client).
  • [tmux] tmux rewrites . and : in session names to _, so topic checks compare the rewritten form and reject those characters.

Open Questions

  • Menu path not yet exercised by hand end to end (n -> b -> topic -> attach). Only helper functions and the menu listing were tested.
  • Does the Location column look right for the new "Migration" session in the live menu?

Key Context

  • Script: projects/claude-foundations/scripts/claude-sessions; commits c32ea46 (menu) and d237789 (headless). Skill: custom-claude-skills/skills/spawn-session, commit a5b82a2.
  • Headless: claude-sessions spawn <folder> --headless [--name topic] [--create]; exit 1 = folder missing, exit 2 = topic in use.
  • Live test: skill spawned "Migration" in ~/dev/claude/projects/migration; Remote Control active.

Process Notes

  • Script docs rule followed: new memory/script-claude-sessions.md plus MEMORY.md index line; skill-spawn-session.md updated.