Command reference
ed longhand
ed longhand belongs to the Longhand extension. Longhand expands the keywords of
Bifrost snippets as you type in any app: type the keyword and a space or
punctuation and it becomes the snippet's text. Snippets and keywords live in
Bifrost, so ed longhand ls lists exactly the keywords Bifrost shows on its
snippets. Expansion is off until you turn it on and needs Input Monitoring and
Accessibility.
Install the extension with ed extensions install longhand. The same controls
are on the Longhand page, the Home card, and the Pause expansion, Resume
expansion and Import Espanso matches actions in Bifrost.
At a glance
| Command | What it does |
|---|---|
ed longhand status |
Prints whether expansion is on and what blocks it. Runs when you type ed longhand with no subcommand. |
ed longhand on |
Resumes expansion and watches typed keywords. |
ed longhand off |
Pauses expansion and removes the keyboard event tap. |
ed longhand ls |
Lists the Bifrost snippet keywords that expand. |
ed longhand import |
Imports Espanso match files into Bifrost snippets. |
Commands
Page operations
The page talks to the extension through ed invoke longhand <operation>. Each
returns {"state": ..., "espansoFolders": [...]}, where state has
configuration (enabled, excluded), active, block, message,
library, snippets, expansions, protectedApps and lastImport.
| Operation | Payload | Result |
|---|---|---|
longhand.read |
{} |
The state |
longhand.enable |
on |
Turns expansion on or off |
longhand.permission |
permission: inputMonitoring or accessibility |
Asks macOS for the permission |
longhand.exclude |
bundleID, excluded |
Adds an app to the exclude list or removes it |
longhand.import.preview |
paths (absolute files or folders) |
files, snippets, skipped and notes, without changing Bifrost |
longhand.import |
paths |
Imports into Bifrost and sets lastImport |
actions.catalog lists pause or resume, and import.espanso. Run one with
actions.perform and {"actionID":"resume"}.
Exit codes
| Code | When |
|---|---|
| 0 | The status or list was printed, expansion was turned on or off, or the import ran. |
| 1 | An import failed: a file is missing, unreadable or not Espanso YAML, or Bifrost is off. |
| 2 | The command line was wrong: an unknown flag or a missing path. |
| 4 | Longhand is not installed or enabled. |
Notes and gotchas
- Edit snippets and keywords in Bifrost settings. A snippet without a keyword never expands.
onprints the missing permission when Input Monitoring or Accessibility is not allowed; the keyboard is watched only once both are.- Keywords never expand in password fields, while secure input is on, in password managers or in apps you exclude on the page.
Where to go next
ed bifrostfor the snippet libraryed permissionsfor Input Monitoring and Accessibility- All
edcommands