HomeTutorials › Sessions & Daemon
Sessions & Daemon

Attach, Detach, List, Delete

#007 0:14 Part of the Rysh video series

Four commands manage every session's whole lifecycle from outside.

Attach, Detach, List, Delete — 0:14 walkthrough

What you'll see

  1. rysh list-sessions -- name, state, and PID of each session.
  2. rysh attach my-project -- reopen the TUI.
  3. rysh detach my-project -- gracefully detach a running session from outside.
  4. rysh delete-session my-project -- kills the process and purges the NATS data directory.

Commands shown

rysh list-sessions
rysh attach my-project
d
rysh detach my-project
rysh delete-session my-project
rysh list-sessions

Keys used

EnterCtrl+o

Transcript

0:00Four commands manage a session's whole lifecycle from outside the TUI.

0:05rysh list-sessions shows every session, its state, and its process ID.

0:14rysh attach reopens a session's TUI exactly where you left it.

0:22And rysh detach gracefully detaches a running session from outside -- no need to be inside it.

0:31rysh delete-session tears it all down: it kills the process and purges the session's NATS data directory.

Key takeaway
attach, detach, list-sessions, and delete-session give you full lifecycle control from the shell.