/herdr:herdr-appfrom herdr
Herdr 桌面窗口面:spaces/tabs/panes 的显示与排布,herdr-app 命令 (do space.new/tab.new/pane.split/agent.focus、ls/status/commands/check/shot)。 Use when 要开空间/分屏/聚焦/切 tab、驱动用户看的窗口、或开发 mod 与 layout 时。 For agents 终端编排走 herdr-core(hc),不走 herdr-app。
Ships in herdr. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Herdr shows spaces, tabs and panes. herdr-core (hc) runs their terminals
and keeps them alive when the window closes. Use herdr-app only to change
what the person sees. For starting, reading, messaging, waiting on or cleaning
up agents and programs, read hc --skill and use hc.
Your terminal address is $HC_TERMINAL_ID; it is not a pane ID.
herdr-app ls # spaces > tabs > terminals, including pane IDs
herdr-app status # current layout, focus, overlays, zoom and file/mod errors
herdr-app commands # available commands, arguments and descriptions
ls and status talk to the running window, not a new app. commands
prints the built-in command list even without an open window. Do not launch bare
herdr-app to inspect it: that opens or raises the window. Do not stop,
signal or restart the person's app or core. A window closing does not kill
its terminals.
app.check_updates checks for newer releases. Settings reports "Up to date"
only after a successful check; on failure, check the connection and retry.
Package-managed cores are checked but updated through their package manager.
Dismiss a core update error with its × or overlay.close {id:"core-update-error"};
it stays dismissed until the error changes or the update recovers.
New spaces and tabs are shown immediately: only create them when asked.
To start one the person will look at later without moving them there, pass
--focus false:
herdr-app do space.new --name eng-123 --folder ~/code/app/eng-123 --argv '["claude"]' --task "Implement ENG-123" --focus false
Pick an explicit, useful name for every new space and tab; don't rely on
default names. Use IDs from ls rather than guessing or acting on the wrong
focused pane.
herdr-app do space.new --name api --folder /path/to/api
herdr-app do tab.new --name "fix login" --argv '["claude"]' --task "Look at the login bug"
herdr-app do pane.split --direction right --pane p12
herdr-app do agent.focus --terminal t7
For a remote space:
herdr-app do space.new --name "remote api" --machine vps --folder /srv/api
The folder is on that machine; tabs and splits in the space stay there.
New-space keys and clicks follow the focused space's machine. Script commands
without --machine still use this computer; --machine '' explicitly chooses it.
The agent menu checks and starts agents in the remote Unix user's
login/interactive shell (sh, bash, zsh, dash, ksh or fish), including its
configured PATH. Other shells keep the sh launcher.
terminal.open --folder /path --place down starts the split in that folder,
including when --argv supplies a program. Without --folder, it follows the
focused terminal's folder. If an inherited local folder was deleted, new spaces,
tabs and splits retry in that machine's home. An explicit invalid folder
still fails.
hc machine ls lists machines. Use hc run --on vps ..., hc exec --on vps ...
and hc file ... --on vps ... for remote work, not your local file tools.
do accepts --key value arguments (JSON for arrays/objects) or one JSON
object. Unknown argument names fail and list valid names. Target IDs (id,
pane, space, target, terminal) must be strings; other non-null types fail before
the current-target default can apply. Null keeps its omitted-argument meaning.
Use commands to confirm the command's exact shape:
herdr-app do pane.split '{"direction":"right","pane":"p12"}'
pane.swap {pane?, direction | target} trades the places of pane (default:
the focused one) and its neighbor in a direction, or target, another pane of
the same tab. Give direction or target, not both. Focus stays with the same pane:
herdr-app do pane.swap '{"pane":"p12","target":"p14"}'
terminal.select_all {terminal?} selects a terminal's whole screen and scrollback,
ready for terminal.copy. Without a target it follows keyboard focus. In vim and
other alternate-screen apps, it selects only that screen. Cmd+A runs it on macOS;
Linux and Windows have no default, so Ctrl+A stays with the shell.
terminal.select {terminal?, at?: {row, col} | "cursor", mode?: "cell" | "word" | "line"}
replaces the selection, at the program cursor by default. Cells are zero-based; rows
count from the oldest retained history through the active screen. Word and line
match double/triple click. terminal.adjust_selection {terminal?, direction} moves
the inclusive moving end and follows it in the view: left, right, up, down, page_up,
page_down, home, end, line_start, line_end. It fails without a selection.
terminal.clear_selection {terminal?} clears it; terminal.copy copies the focused terminal's selection.
These add no default keys or built-in copy mode. Mods read the inclusive selection
endpoints from focused().selection or terminals(); null means none (or no
attached view). Use selection.end as a copy-mode cursor. Selection facts update
when the selection changes, without refreshing readers on ordinary terminal output.
terminal.search opens a find bar in the focused terminal. It searches that
terminal's screen and scrollback; Enter and Shift-Enter move between matches,
Escape closes the bar while its find field has focus, and each terminal keeps its own query (reopening selects it, so typing replaces it).
Clicking the terminal while the bar is open puts typing, including Escape, back in the program; the bar and its matches stay.
It prints the created IDs (for example { "pane": "...", "terminal": "..." })
or { "error": "..." } and exits 1. Read the result, then inspect ls or
status to confirm. Commands invoked by an agent never open a missing-argument
dialog: supply all required arguments. A successful launch reply means the
terminal was created, not that its program started correctly. If it exits
with a nonzero code within two seconds, the window shows an error toast with
the exit code and last output lines.
A terminal started with hc opts into the window with herdr.space=<id>.
herdr.tab=<id> chooses its tab; without it, Herdr creates a tab in that space.
Unlabeled workers stay hidden. Do not add labels just to run a background
worker. Use app commands when the
user wants to see a new tab or split, hc for orchestration that need not change
the screen.
First read ~/.config/herdr-app/AGENTS.md (or $HERDR_APP_HOME/AGENTS.md if
set). It is the installed guide to settings, layouts, commands and mods.
Read the generated .d.ts files beside it for full API details; do not edit
those files or the generated guide. The app rewrites them on start.
terminal_line_height (default 1, 0.8..2) adjusts terminal rows;
terminal_scroll_speed (default 1, 0.1..5) adjusts wheel and trackpad
scrolling, including mouse reports. Set them in settings.json or the
layout's look; the layout wins.~/.config/herdr-app; HERDR_APP_HOME selects another.mods/<name>/ with main.js and optional mod.json.
They are trusted JavaScript with command and network access.
"focusable": true in mod.json lets pane.go move onto a copy; it receives
"focus" from nextCommand() and focuses its own keyboard handle.watchFolder(dir) promise has cancel(); cancel it when the folder
is no longer shown. It resolves with [] and releases only that call.mod.clone before editing.
Shipped layouts likewise use layout.clone for a personal copy.
Discover required arguments with herdr-app commands.status; a still-working screen is not proof the edit worked.cx across callbacks; each
callback receives its own. Native animations, not redraw timers, keep
the window cheap to run. Root on_size_change((size, cx) => …) reports
logical pixels after layout, including resizes without pointer movement.
Optional View.close(cx) gets one bounded final call; start cleanup there,
not in an earlier task. The installed guide explains its 250 ms quit budget
and which cleanup commands go out before shutdown.After every mod change:
herdr-app check ~/.config/herdr-app/mods/<name>
herdr-app status
herdr-app shot /tmp/mod.png # then look at the picture
check loads the mod and renders it once. It exits nonzero with the exact
error. Its shared state starts empty and stays in memory; it leaves shared.json
untouched. Never call a mod done without a passing check. Then confirm it is
shown correctly in the running window with shot; don't claim a visual
check you haven't made.
herdr-app shot [file.png] saves the window's last frame and prints its
absolute path (default: herdr-shot.png in your current folder). It is the
app's own rendering at full pixel size: terminals, images, overlays and
floats included, even when the window is covered or minimized. No screen
capture or permissions. It needs a running window that has drawn a frame;
HERDR_APP_HOME selects the window, as for status.
If Herdr misbehaves, herdr-app feedback "<what happened>" drafts a report.
The person reviews and sends it; it does not silently send feedback.
Never experiment with pointer/key automation on the person's real display.
When developing the app on Linux, its scripts/sandbox provides an isolated
home, core and display: up, do, status, shot, then down when done.
Never stop a server or session you didn't start.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub raystyle/harness-plugins --plugin herdr3 skills in this plugin
/herdr-coreUse herdr-core (its CLI is hc) whenever you want sub-agents, to talk to or coordinate other agents, run background tasks or servers, run long-running commands, read or control terminals, or work on another machine; also to show or arrange things in the Herdr window or build Herdr mods and layouts. Prefer it over your own sub-agent tool, shell '&', nohup or tmux./views-devviews mod 开发与安装规范(herdr-app 数据面板,任意项目自持):命名防撞、 数据道/视图道标准形、调试闭环、安装卸载、三条铁律。 Use when 任何项目要开发/安装/卸载自己的 views mod(数据面板、拓扑视图、 资源矩阵),或 views mod 渲染出错、数据断链排查时。 触发词:views、views mod、数据面板、面板开发、mod 开发、mod 安装。 不要用于 herdr-app 布局结构调试(走 herdr-app --skill)或 mods 目录写状态。Other plugins' skills for the same job