omp-ghostty-fork-tab0.1.0
omp extension: bare /fork opens the forked session in a new Ghostty tab on macOS
Built for omp
The author tagged this package oh-my-pi.
Reports 0
No reports yet.
Readme
omp-ghostty-fork-tab
An omp extension for macOS Ghostty: typing a bare /fork opens a new Ghostty tab running omp --fork <current session>, switches to it, and leaves the parent session running in the original tab.
omp's built-in /fork pane|window|tab only supports tmux, Zellij, Herdr, CMUX, and Orca. This extension adds the equivalent for Ghostty through its AppleScript new tab API.
Behavior
/forkis intercepted only when running directly in Ghostty on macOS (not inside tmux, Zellij, screen, CMUX, Herdr, wmux, or Orca). Everywhere else the built-in/forkruns unchanged.- The child starts from the persisted transcript with
omp --fork, so it is a real fork: the new session recordsparentSessionand inherits the provider prompt-cache key. - The new tab is selected explicitly, so you land in the forked conversation.
- Streaming sessions ask for confirmation first; in-memory sessions and vibe mode are rejected.
--profile,PI_CONFIG_*/XDG scope variables are forwarded to the child.
Install
From git:
omp plugin install github:Rinai-R/omp-ghostty-fork-tab
Or clone and link a local checkout:
git clone https://github.com/Rinai-R/omp-ghostty-fork-tab
omp plugin link ./omp-ghostty-fork-tab
Restart omp (or run /restart) after installing. The first launch triggers the macOS Automation permission prompt for controlling Ghostty.
Notes
- TypeScript extension module loaded directly by omp's Bun runtime; no build step.
- The Ghostty launch is done by generating AppleScript and running it through
osascript. - The extension does not take over
/fork tab,/fork window, or/fork pane; those keep omp's built-in behavior.
Release
Pushing a v* tag runs .github/workflows/release.yml: it checks the tag against package.json, smoke-tests the extension with Bun, publishes to npm with provenance, and creates the GitHub release.
git tag v0.1.0
git push origin v0.1.0
The workflow needs NPM_TOKEN as an Actions secret (or variable). Bump package.json before tagging; a mismatched tag fails the run.