explaingit

yigitkonur/native-shortcuts-herd

12TypeScriptAudience · developerComplexity · 2/5ActiveSetup · easy

TLDR

npm installer that wires familiar macOS keyboard shortcuts (cmd+t, cmd+n, cmd+1 through 9) into the Ghostty terminal via the herdr workspace manager.

Mindmap

mindmap
  root((native-shortcuts-herd))
    Inputs
      Profile flags
      Existing Ghostty config
      herdr install state
    Outputs
      Ghostty keybindings
      herdr keys sections
      Timestamped backups
    Use Cases
      Make Ghostty feel like Chrome tabs
      Apply chrome-tabs profile
      Restore previous herdr config
    Tech Stack
      TypeScript
      npm
      Ghostty
      herdr

Things people build with this

USE CASE 1

Make Ghostty behave like Chrome or iTerm with cmd+t for tabs and cmd+1-9 for workspace jumps

USE CASE 2

Run a fully scripted install with --yes and --install-herdr in a dotfiles setup

USE CASE 3

Apply a named profile like chrome-spaces or chrome-tabs and diff the planned writes first

USE CASE 4

Cleanly uninstall every managed change and restore previous herdr keybindings

Tech stack

TypeScriptnpmGhosttyherdr

Getting it running

Difficulty · easy Time to first run · 5min

Needs Ghostty plus herdr 0.5.10 or newer; the installer can fetch herdr into ~/.local/bin if missing.

In plain English

native-shortcuts-herd is a small npm installer whose job is to make the Ghostty terminal feel like a normal macOS app when you also use a tab and workspace manager called herdr. The author notes that Ghostty is fast and native, and that herdr already provides workspaces, tabs, panes, and direct number jumps, but the keyboard shortcuts that macOS users have in their hands from Chrome, Safari, Arc, iTerm, or Warp do not work without extra setup. This package writes the configuration that connects the two. The usual way to run it is npx. The command npx native-shortcuts-herd@latest install walks the user through setup, while a fully scripted version with flags like --yes, --install-herdr, and --glass-theme runs without prompts. If herdr is missing or older than version 0.5.10, the installer can download the right release into ~/.local/bin/herdr and check the SHA256 before writing it. After the install, common Mac shortcuts behave the way most users expect. cmd+t opens a new herdr tab, cmd+n opens a new workspace, cmd+w closes the current tab, cmd+1 through cmd+9 jump to workspace 1 through 9, and ctrl+tab and ctrl+option+tab cycle workspaces and tabs. Every one of these is configurable through profiles such as chrome-spaces or chrome-tabs. The README lists each Ghostty trigger, the text sequence Ghostty sends, and the herdr key event that finally fires. On disk the tool only touches files it owns. It adds one managed include line to the Ghostty config, writes its own keybindings to ~/.config/native-shortcuts-herd/ghostty.conf, updates the [keys] and [keys.indexed] sections in herdr, and keeps the previous herdr values in a state file so they can be restored. Timestamped backups are written before any change. Extra commands round out the lifecycle. apply reapplies a profile, diff shows the planned writes, doctor --json prints the state of Ghostty and herdr, and uninstall --yes removes every managed change.

Copy-paste prompts

Prompt 1
Run npx native-shortcuts-herd install on my Mac and explain what files it will touch before I confirm
Prompt 2
Show me the keybindings native-shortcuts-herd writes for the chrome-tabs profile and how cmd+w maps to herdr
Prompt 3
Use native-shortcuts-herd doctor --json to debug why cmd+1 is not switching workspaces in Ghostty
Prompt 4
Walk me through native-shortcuts-herd uninstall --yes and confirm my original herdr config is restored
Open on GitHub → Explain another repo

Generated 2026-05-22 · Model: sonnet-4-6 · Verify against the repo before relying on details.