# Terminal UI keybindings

> For the complete documentation index, see [llms.txt](https://docs.ringleader.dev/llms.txt).


> Every key the TUI binds, grouped by scope: global navigation and the per-view actions.


This page lists every key the TUI binds. Inside the TUI, the footer shows the
keys that work where you are, and `?` lists the keys for the current tab.

## Global

These work on every tab and on the Related view. Inside the describe,
troubleshoot and logs views, and while a dialog, a prompt or the palette is open,
only that view's own keys work.

| Key | Action |
|-----|--------|
| `1` | Workstations tab. |
| `2` | Configs tab. |
| `3` | Bindings tab. |
| `4` | SSH Keys tab. |
| `5` | Grants tab. |
| `?` | List the keys for the current tab. The arrow and page keys scroll the list, and any other key closes it. |
| `Ctrl+P` | Open the command palette. |
| `↑` / `k` | Move selection up. |
| `↓` / `j` | Move selection down. |
| `g` / `G`, `Home` / `End` | Jump to top / bottom. |
| `PgUp` / `PgDn` | Move a page up / down. |
| `n` | Choose the namespace scope. |
| `/` | Filter the current table. |
| `O` | Toggle mine-first ordering. |
| `o` | Toggle mine-only filter. |
| `+` | Open the create wizard for this kind (not on Grants or the Related view). |
| `x` | On a workstation, open the Related view. On a config, binding or SSH key, switch to the Workstations tab, filtered to the workstations it applies to. |
| `R` / `Ctrl+R` | Refresh now. |
| `L` | Open the logs view. |
| `q` / `Ctrl+C` | Quit. |

## Workstations

| Key | Action |
|-----|--------|
| `S` | Start. |
| `s` | Stop. |
| `r` | Restart. |
| `Enter` | SSH shell. |
| `V` | View / describe. |
| `t` | Attach a `tmux` session. |
| `D` | Describe (same view as `V`). |
| `T` | Troubleshoot. |
| `x` | Related objects. |
| `e` | Edit as YAML. |
| `c` | Copy. |
| `d` | Delete. |

## Configs

| Key | Action |
|-----|--------|
| `Enter` / `V` | View. |
| `e` | Edit as YAML. |
| `c` | Copy. |
| `d` | Delete. |

## Bindings

| Key | Action |
|-----|--------|
| `a` | Enable / Disable. |
| `t` | Retarget at another workstation. |
| `Enter` / `V` | View. |
| `e` | Edit as YAML. |
| `c` | Copy. |
| `d` | Delete. |

## SSH Keys

| Key | Action |
|-----|--------|
| `a` | Enable / Disable forwarding. |
| `D` | Describe. |
| `Enter` / `V` | View. |
| `e` | Edit as YAML. |
| `c` | Copy. |
| `d` | Delete. |

## Grants

| Key | Action |
|-----|--------|
| `a` | Enable / Disable the share. |
| `D` | Describe. |
| `Enter` / `V` | View. |
| `e` | Edit as YAML. |
| `c` | Copy. |
| `d` | Delete. |

## Describe and Troubleshoot views

| Key | Action |
|-----|--------|
| `y` | Describe only: toggle key/value and raw YAML. |
| `c` | Describe only, Workstations only: toggle the resolved configuration. |
| `z` | Describe only: toggle UTC and local timestamps. |
| `↑` / `k`, `↓` / `j` | Scroll a line up / down. |
| `PgUp` / `PgDn` | Scroll a page up / down. `Space` also scrolls a page down. |
| `g` / `G`, `Home` / `End` | Jump to the top / bottom. |
| `esc` / `q` | Back to the list. |

## Command palette

`Ctrl+P` lists every command available in the current view. Type to narrow the list.

| Key | Action |
|-----|--------|
| `↑` / `↓` | Select a command. |
| `Enter` | Run it. |
| `Backspace` | Delete the last character you typed. |
| `esc`, `Ctrl+C` or `Ctrl+P` | Close the palette. |

## Logs view

`L` opens the logs view: the log of this `rl tui` session, colored by level. It
opens at the newest line and follows new lines as they arrive. Scrolling up
stops following, and `G` starts it again. The TUI also writes this log to
`tui.log` in your data directory, and the view's header shows that path.

The logs view's filter takes the same kind of terms as the table filter. A
`field:value` term matches `level`, `msg`, or any other field a log line carries,
for example `level:error` or `msg:timeout`.

| Key | Action |
|-----|--------|
| `/` | Filter the log. In the filter prompt, `Enter` keeps the filter and `esc` clears it. |
| `↑` / `k`, `↓` / `j` | Scroll a line up / down. |
| `PgUp` / `PgDn` | Scroll a page up / down. `Space` also scrolls a page down. |
| `g` / `Home` | Jump to the oldest line. |
| `G` / `End` | Jump to the newest line and follow new ones. |
| `esc` | Clear the filter, or go back to the list when there is none. |
| `q` | Back to the list. |

## Related view

| Key | Action |
|-----|--------|
| `Enter` / `V` | View the selected related object. |
| `D` | Describe it. |
| `x` | Switch to the Workstations tab, filtered to the workstations the selected object applies to. |
| `esc` | Back to the Workstations tab. |

## Dialogs and prompts

A confirmation dialog has a button named for the action, such as **Delete**, and
a **Cancel** button. It opens with **Cancel** selected.

| Key | Action |
|-----|--------|
| `←`, `h` or `Shift+Tab` | Select the action button. |
| `→`, `l` or `Tab` | Select **Cancel**. |
| `Enter` | Choose the selected button. |
| `esc`, `n` or `Ctrl+C` | Cancel. |

In the other prompts and lists, `esc` does this:

| Where | What `esc` does |
|-------|-----------------|
| The `/` filter prompt | Clears the filter and closes the prompt. `Enter` keeps the filter instead. |
| The copy prompt | Asks whether to abort the copy. |
| The create wizard | Asks whether to discard the new object. |
| A list of choices, such as the namespace list | Closes the list without choosing. |

