Skip to content

TUI: show other-directory sessions in /resume picker - #669

Open
nicklisac wants to merge 1 commit into
huggingface:mainfrom
nicklisac:resume-picker-other-directories
Open

TUI: show other-directory sessions in /resume picker#669
nicklisac wants to merge 1 commit into
huggingface:mainfrom
nicklisac:resume-picker-other-directories

Conversation

@nicklisac

@nicklisac nicklisac commented Aug 28, 2026

Copy link
Copy Markdown

The resume picker previously listed only sessions from the current working directory, so following up on a session from another project required knowing its id. It now lists current-directory sessions first, then an "Other Directories" section with every other session, each prefixed by its slim working directory.

Description

  • Current-directory sessions are listed first (newest-first), followed by an "Other Directories" divider and all other sessions (also newest-first).
  • Rows use compact relative ages (now / 5m ago / 2h ago / yesterday / 3d ago / else Jun 19). The model name is shown last so it truncates before the title, and the picker panel is widened to fit.
  • The "Other Directories" divider is a non-selectable row: up/down skip it and clicking it does nothing.
  • Resuming a session from a different directory appends the target directory to the confirmation toast, e.g. Resumed session: abc (~dir).

User experience

Resuming a session from another project no longer requires knowing its id or path — one grouped list with compact timestamps and a clearly separated "Other Directories" section.

Manual validation

  1. Run uv run tau in a directory that has sessions, then open /resume.
  2. Confirm current-directory sessions are listed first.
  3. With sessions present elsewhere, confirm they appear under "Other Directories" with a slim path on the left.
  4. Use up/down to confirm the divider is skipped and Enter selects the highlighted session; clicking the divider does nothing.
  5. Resume a foreign-directory session and confirm the toast shows (~path).

Checks

  • uv run pytest
  • uv run ruff check .
  • uv run ruff format --check .
  • uv run mypy

Screenshots

Screenshot_2026-08-28_08-32-55

This PR was written by me with the assistance of Qwen 3.8 27B UD-Q8_K_L using Tau.

The resume picker only listed sessions from the current working
directory, so following up on a session from another project required
knowing its id. It now lists current-directory sessions first, then an
"Other Directories" section with every other session, each prefixed by
its slim working directory.

- Compact relative ages (now / 5m ago / 2h ago / yesterday / Jun 19)
  replace full timestamps; the model name is shown last so it truncates
  before the title; the picker panel is widened to match.
- The "Other Directories" divider is a non-selectable row (a CSS class,
  not an id): keyboard up/down skip it, and clicking it does nothing.
- When resuming a session from a different directory, the confirmation
  toast notes the new working directory, e.g. "Resumed session: abc (~dir)".
- The list rebuilds synchronously on each keystroke (as in the other
  pickers), keeping the DOM and row map in lockstep so rapid typing can't
  desync; navigation clamps an out-of-range index defensively.
- _short_path renders the home directory as "~" rather than "~/.".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant