Command line
glaze ls
List the sessions on the target tmux server with window counts and starting directories.
ls answers the question “what is running right now?” without you leaving the shell. It is a thin table over tmux list-sessions, with the one addition that it knows which session you are in.
$ glaze ls
NAME WINDOWS PATH
daemon-run* 3 /home/v/runs/arasaka
scratch 1 /tmp
Flags
| Flag | Description |
|---|---|
--socket-path / --socket-name | A custom tmux socket. See Custom sockets. |
Columns
| Column | Content |
|---|---|
NAME | The session name. An asterisk marks the session of the pane that runs ls. |
WINDOWS | The number of windows in the session. |
PATH | The starting directory of the session. |
Glazier marks the current session only when you run ls in a pane of the same tmux server. In a pane of a different server, for example with --socket-name, no session has the mark.
No server
When no tmux server runs, ls writes nothing to stdout and exits with code 0. The table goes to stdout and the log goes to stderr, so a script can read the table alone.
An exit code of 4 is different: Glazier cannot reach tmux at all, for example because tmux is not on PATH. See Exit codes.