Skip to content

Session list: include TTY and tmux pane metadata #89

@benvinegar

Description

@benvinegar

Problem

When multiple Hunk sessions are running, it's hard to tell which session corresponds to which terminal window. The only identifying info is repo path and title, which can be identical across sessions.

Suggestion

Add optional tty and tmuxPane fields to HunkSessionRegistration so hunk session list (and the daemon API) can surface which terminal a session belongs to.

Available at registration time:

  • TTY path: readable via ttyname() or /proc/self/fd/0 readlink
  • TMUX_PANE: env var set by tmux (e.g. %3)
  • TMUX: env var with the tmux socket path

Example output:

5539f294  hunk show HEAD  [tmux %3]
  repo: /Users/benvinegar/Projects/hunk

This came up during a real debugging session where a stale process kept a ghost session registered, and it was unclear which session was the live visible one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    uiUser interface improvements

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions