Plugins

trm supports 10 built-in pane plugin types managed by an extensible plugin registry. Each pane in the grid can be a different type, configured via [[panes]] blocks in your session file.

All plugins share these common fields:

FieldTypeDefaultDescription
typeString"terminal"The plugin type identifier
titleString?Auto-generatedCustom title for the pane's title bar

Plugin Registry

trm uses a plugin registry that maps plugin type names to factory functions. All 10 built-in plugins are registered at startup. The registry supports:

  • Plugin discovery — list all available plugin types
  • Plugin instantiation — create plugins by name
  • Extensibility — future support for dynamic plugin loading

terminal

Full VT100/VT220 terminal emulator with a PTY-backed shell. This is the default pane type.

[[panes]]
type = "terminal"
title = "Dev Shell"
command = "/bin/zsh"
cwd = "~/projects/myapp"
watermark = "DEV"
initial_commands = ["echo 'Hello!'", "ls -la"]
# env = [["NODE_ENV", "development"], ["PORT", "3000"]]
FieldTypeDefaultDescription
commandString?$SHELLShell or command to execute
cwdString?InheritedWorking directory (supports ~ expansion)
watermarkString?NoneLarge faded text displayed behind the terminal content, useful for identifying panes at a glance
initial_commandsString[]?NoneCommands to run automatically after the shell starts. Each is sent with a carriage return
env[String, String][]?NoneExtra environment variables as [key, value] pairs

Features:

  • GPU-rendered text via Ghostty's Metal/OpenGL renderer
  • Full ANSI color support (16 colors + 256-color + true color)
  • Scrollback history
  • Mouse text selection (click-drag, double-click for word selection)
  • Copy/paste via system clipboard
  • VT100 escape sequence handling
  • Broadcasts input when broadcast mode is active

webview

Embedded web browser using macOS WKWebView. Click inside the pane to interact -- keyboard input is handled natively by WKWebView when focused.

[[panes]]
type = "webview"
title = "Documentation"
url = "https://docs.rs"
FieldTypeDefaultDescription
urlString?NoneURL to load in the embedded browser

Features:

  • Full web rendering via WebKit
  • JavaScript support
  • Navigation via the Text Tap API (navigate action)
  • Native macOS scrolling and interaction
  • Automatically positioned and resized with the grid layout

Note: WebView panes are macOS-only.


notes

Editable text area using macOS NSTextView. Supports both in-memory scratch pads and file-backed persistent notes.

# In-memory scratch pad
[[panes]]
type = "notes"
title = "Scratch Pad"
content = "Type anything here..."

# File-backed persistent notes
[[panes]]
type = "notes"
title = "TODO List"
file = "~/trm-todo.md"
FieldTypeDefaultDescription
contentString?NoneInitial content (used when no file is specified)
fileString?NoneFile path for persistent storage. Content is loaded on startup and auto-saved on close

Features:

  • Native macOS text editing
  • File persistence (when file is specified)
  • Content manipulation via the Text Tap API (set_content action)

Note: Notes panes are macOS-only.


screen_capture

Mirrors another application's window into a trm pane. Uses macOS ScreenCaptureKit.

# By application bundle ID
[[panes]]
type = "screen_capture"
title = "Safari Mirror"
target = "com.apple.Safari"

# By window title
[[panes]]
type = "screen_capture"
title = "VS Code Mirror"
target_title = "trm"
FieldTypeDefaultDescription
targetString?NoneApplication bundle ID to capture (e.g., "com.apple.Safari")
target_titleString?NoneTarget a specific window by its title string

Note: This plugin is a work in progress. macOS-only.


file_browser

Interactive file browser that displays a directory tree.

[[panes]]
type = "file_browser"
title = "Project Files"
path = "~/projects/myapp"
FieldTypeDefaultDescription
pathString?"."Root directory to browse (supports ~ expansion)

Features:

  • Tree view with expandable directories
  • File size display
  • Keyboard navigation (arrow keys, Enter to expand/collapse)
  • Auto-refresh on changes

process_monitor

Displays a list of running processes sorted by CPU usage, similar to top.

[[panes]]
type = "process_monitor"
title = "Processes"
refresh_ms = 2000
FieldTypeDefaultDescription
refresh_msInteger?2000Refresh interval in milliseconds

Features:

  • PID, user, CPU %, memory %, and command columns
  • Sorted by CPU usage
  • Scrollable list
  • Auto-refresh at the configured interval

log_viewer

Tails a log file and displays its contents with auto-scroll.

[[panes]]
type = "log_viewer"
title = "System Log"
file = "/var/log/system.log"
FieldTypeDefaultDescription
fileString?"/var/log/system.log"Path to the log file to tail. Also accepts path as an alias

Features:

  • Tails the file (reads new content as it appears)
  • Scrollable history (up to 10,000 lines)
  • Incremental reads (efficient for large log files)

markdown_preview

Renders Markdown content with syntax highlighting for headings, code blocks, lists, and emphasis.

# From a file
[[panes]]
type = "markdown_preview"
title = "README"
file = "~/projects/myapp/README.md"

# Inline content
[[panes]]
type = "markdown_preview"
title = "Preview"
content = "# Hello\n\nThis is **bold** text."
FieldTypeDefaultDescription
fileString?NoneMarkdown file to render. Also accepts path as an alias
contentString?NoneInline Markdown content (used when no file is specified)

Features:

  • Heading rendering with color differentiation
  • Code block highlighting
  • Bold and italic text support
  • Scrollable content

system_info

Displays live system information including hostname, OS version, CPU, memory, disk, and network statistics.

[[panes]]
type = "system_info"
title = "System"
refresh_ms = 3000
FieldTypeDefaultDescription
refresh_msInteger?3000Refresh interval in milliseconds

Features:

  • Hostname and OS version
  • System uptime and load averages
  • CPU usage percentage
  • Memory usage
  • Disk usage
  • Network interface information

git_status

Displays Git repository status, including branch, modified files, and recent log.

[[panes]]
type = "git_status"
title = "Git"
repo = "~/projects/myapp"
FieldTypeDefaultDescription
repoString?"."Path to the Git repository. Also accepts path as an alias

Features:

  • Current branch display
  • Modified/staged/untracked file listing with status indicators
  • Recent commit log
  • Multiple views: Status, Log, Diff
  • Auto-refresh on changes

Mixing Plugin Types

You can combine any plugin types in a single session. Here is an example that uses five different types in a 2x3 grid:

title = "Full Stack Dev"
rows = 2
cols = 3

[[panes]]
type = "terminal"
title = "Shell"
cwd = "~/projects/myapp"
watermark = "DEV"

[[panes]]
type = "terminal"
title = "Server"
initial_commands = ["npm run dev"]

[[panes]]
type = "webview"
title = "Preview"
url = "http://localhost:3000"

[[panes]]
type = "file_browser"
title = "Files"
path = "~/projects/myapp"

[[panes]]
type = "git_status"
title = "Git"
repo = "~/projects/myapp"

[[panes]]
type = "system_info"
title = "System"