03 · Actions and recipes

Actions and recipes

There are seven types of action. This page describes what each one does and which fields it uses, with examples you can copy straight into Settings. For how to write match conditions and templates, see Writing rules.

ActionWhat it doesMatch condition and template
Open URLOpens a URL you build in your default browserBoth
Web SearchSearches GoogleBoth
CopyCopies to the clipboardBoth
Run CommandRuns a zsh commandBoth
TranslateTranslates on your MacMatch condition and a language pair
Replace AllRebuilds the whole text with every match expandedNone
Paste ImageHolds a clipboard image for laterNone

Open URL

Opens a URL with the matched text inserted, in your default browser.

Open a Jira ticket from its key

This ships as a default rule with a placeholder domain. Replace it with your own Jira domain.

Type
Open URL
Match condition
[A-Z]{2,10}-\d+
Ignore case
Off
URL to open
https://your-domain.atlassian.net/browse/$0

Selecting WT-3434 opens https://your-domain.atlassian.net/browse/WT-3434. With Ignore case off, a lowercase run like ab-12 in ordinary prose isn't picked up.

Open a GitHub issue or PR from owner/repo#123

Three groups, each inserted into a different part of the URL. GitHub opens pull requests from issue URLs too.

Type
Open URL
Match condition
([\w.-]+)/([\w.-]+)#(\d+)
Ignore case
Off
URL to open
https://github.com/$1/$2/issues/$3

Selecting anthropics/claude-code#42 opens https://github.com/anthropics/claude-code/issues/42.

Open an order in an admin page, using a named group

Groups are inserted by name instead of number, so you don't have to recount them when the pattern grows.

Type
Open URL
Match condition
ORD-(?<order>\d{6,})
Ignore case
Off
URL to open
https://admin.example.com/orders/${order}

Selecting ORD-104822 opens https://admin.example.com/orders/104822. The ORD- prefix is part of the match but not of the URL.

Search an internal wiki for the selection

An empty match condition makes this appear for anything you select. The text goes into a query, so URL encoding is on.

Type
Open URL
Match condition
empty
URL to open
https://wiki.example.com/search?q=$0
URL-encode inserted values
On

Selecting a phrase with spaces or non-Latin characters opens the search results with it correctly encoded.

Searches Google. The template is the search query, not a URL. Just $0 searches the selection as it is. The query is encoded for you.

To use a search engine other than Google, write its search URL as an Open URL rule.

Search only the official documentation

A search operator in front narrows where you look.

Type
Web Search
Match condition
empty
Search query
site:developer.apple.com $0

Selecting NSPasteboard searches for site:developer.apple.com NSPasteboard.

Copy

Copies the matched text, or text built from the template, to the clipboard. With an empty template, the whole match is copied as it is.

While pinned, this action pastes at your cursor instead of copying.

Copy just the domain out of a URL

For when you want part of the selection rather than all of it.

Type
Copy
Match condition
https?://([^/\s]+)
Text to copy
$1

Selecting https://pluck-now.com/guide/ copies pluck-now.com.

Run Command

Runs the template as a zsh command. Insert the selected text with $0 and the other placeholders. Output isn't shown in the panel.

The command runs as you, with your permissions. It can do anything you could type in a terminal. Don't set up rules or commands from sources you don't trust.

Inserted values aren't escaped; they become part of the command as they are. If the selection could contain spaces or punctuation, quote it in the template, as in "$0". Restricting the characters the match condition accepts makes it safer still.

Reveal a selected path in Finder

Opens a file path pasted into a log or a chat message in Finder.

Type
Run Command
Match condition
(?:~|/)(?:[\w.-]+/)+[\w.-]+
Command to run
open -R "$0"

Selecting /Users/you/project/README.md opens Finder with that file selected. The match condition only accepts paths with at least two slash-separated parts and no whitespace, so an and/or in prose doesn't trigger it.

Translate

Detects which language the selection is in and translates it into the other language of the pair you set. With Japanese as Language 1 and English as Language 2, English text gives you Japanese and Japanese text gives you English. There's nothing to switch.

Translation uses macOS's translation feature and runs on your Mac; the text isn't sent to an outside server. The first time you use a language pair, macOS may need to download language data, and the panel offers a button for it. If a pair isn't supported, the panel says so.

Offer translation only for English text

The default Translate rule has an empty match condition and appears for everything. If it gets in the way while you read documents in your own language, narrow it with a match condition.

Type
Translate
Match condition
[A-Za-z][A-Za-z ,.'"()-]{20,}
Language 1
Japanese
Language 2
English

The translation suggestion appears only when the selection contains a run of 21 or more Latin letters and punctuation.

Replace All

Finds every place in the selected text that an Open URL rule matches, and rebuilds the whole text with each of them replaced by its URL. Use it to turn the keys scattered through a paragraph into links while keeping the prose intact.

Selected text
  Please look at WT-1 and WT-2

Result
  Please look at https://your-domain.atlassian.net/browse/WT-1 and
  https://your-domain.atlassian.net/browse/WT-2

Replace All has no match condition or template of its own; you can change only its name, icon, and whether it's enabled. The conditions and URLs come from your Open URL rules, so adding an Open URL rule extends Replace All as well.

The panel works a little differently for this one.

Turn every ticket key in a note into a URL

Replace All itself needs no setup. If the Jira rule above is enabled, this already works.

What you need
One Open URL rule: match condition [A-Z]{2,10}-\d+, URL https://your-domain.atlassian.net/browse/$0
Replace All
Left enabled

Select the line "WT-1234 and WT-5678 by Friday" and a suggestion appears with both keys turned into URLs. ⌃+number replaces the line you selected with it.

Paste Image

When you take a screenshot or copy an image from a browser, a single suggestion with a thumbnail appears. It doesn't react to text.

In Settings, this rule sits under "Rules for images" with an image tag.