Skip to content

project-runner: run in the Herdr app as well as the TUI - #8

Merged
JacobAtchley merged 7 commits into
mainfrom
feat/project-runner-gui
Nov 2, 2026
Merged

JacobAtchley merged 7 commits into
mainfrom
feat/project-runner-gui

Conversation

@JacobAtchley

Copy link
Copy Markdown
Owner

The project-runner script picker now works in the Herdr desktop app as well as the TUI. It follows the same pattern as git-glance (#7): the Rust binary does the work and prints JSON, and an app mod draws the result.

What changed

  • Rust: project-runner scripts --cwd <dir> [--query <q>] prints the project (folder, name, package manager) and the scripts, ranked by the TUI's own matcher. Each script includes highlight runs already split into whole letters, plus the command to launch it. Exit codes are 0 for ok, 1 when there's no usable package.json, and 2 for bad arguments. project-runner ui is unchanged.
  • App mod (plugins/project-runner/gui/project-runner/): a centred popup with the TUI's keys (enter new tab, ctrl-v/ctrl-x splits, ctrl-p/ctrl-n, ctrl-u, esc/ctrl-c). Clicking selects a script and double-clicking runs it. The list scrolls to keep the selection visible, and launching waits for the newest results.
  • Launching: a new tab runs the script inside your login shell, which stays open afterwards. A live probe showed that the app runs a split's command without a shell, so the pane died when the script ended. Splits now get split_argv, the same shell wrapper the app uses for tabs, and a re-test showed the split stays open.
  • README: a new section, "In the Herdr app" (key: "cmd-r": "mod.open:project-runner").
  • Spec: docs/superpowers/specs/2026-11-02-project-runner-gui-design.md. Plan: docs/superpowers/plans/2026-11-02-project-runner-gui.md.

Testing

  • just ci passes: 40 Rust tests for project-runner (including an end-to-end test of the exit codes), 12 Node tests, fmt and clippy.
  • just gui-check passes for all three app mods.
  • In a throwaway space I took screenshots of the popup with real data, including a 30-script list that fits the dialog.
  • Not yet tried by hand: typing in the popup, launching from it, and clicking. I can't send keys to the app.

Known gaps

  • A single click on the already-selected row doesn't run it; double-click does.
  • One failed call to the binary while typing replaces the list with an error screen.
  • The fish shell wrapper isn't tested on a real fish, and it breaks if the $SHELL path contains a space.
  • Long script names are cut off with no ellipsis.

🤖 Generated with Claude Code

https://claude.ai/code/session_017SHDkxeudXCfQdJrUungWE

JacobAtchley and others added 7 commits November 2, 2026 13:31
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017SHDkxeudXCfQdJrUungWE
The Herdr app starts a new tab's program inside the login shell but runs a
split's argv bare, so the CLI also gives split_argv: the app's own wrapper.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017SHDkxeudXCfQdJrUungWE
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017SHDkxeudXCfQdJrUungWE
…s keys on the newest list

- the list draws only the rows that fit and scrolls to follow the selection
- a launch pressed while a newer query is on its way runs on that answer
- the query input takes focus again after the overlay opens and after a click

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017SHDkxeudXCfQdJrUungWE
@JacobAtchley
JacobAtchley merged commit f7d9dd8 into main Nov 2, 2026
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant