SearchLink

A macOS Service for Markdown writers that allows you to add hyperlinks while writing without switching to your browser.

Introduction

SearchLink is a System Service for macOS which handles searching multiple sources and automatically generating Markdown links for text.

It works in a few ways:

  • Run a quick search on a single selection, and have the selection replaced with the resulting url (and optional title) as a Markdown inline link, a Markdown reference, or just a plain url.
  • Run a single search and have the results put on your clipboard, perfect for using from scripts and launchers (e.g. LaunchBar or Alfred).
  • The "bracket" format, which allows you to just write, marking things to link as you go. When you're done, you can run it on the full document and --- if your queries were good --- have your links generated automatically without ever opening a browser.

This has replaced the "Auto-link web search" service in the Markdown Service Tools. The difference is that you can now mark links and specify how they should be searched for, as well as provide alternate query terms for linked text.

Here's a video tutorial from Aaron Dowd (@thepodcastdude):

Intro to SearchLink on YouTube

Documentation

The documentation has moved to a wiki.

Download

There will likely be updates to this as I solve more problems, so keep an eye on this page for new versions. The current source code is available on GitHub.

Download SearchLink 2.3.14.

Bonus for LaunchBar users

With the AppleScript below saved to ~/Library/Application Support/LaunchBar/Actions/Instant Search.scpt, you can use SearchLink as a launcher for the web. Load the action in LaunchBar, type Space and enter a SearchLink simple query (just text with optional !arg at the beginning). When you hit Enter it will grab the first link and load it in the Open URL action. Enter again will open it in your browser, ???C will copy it to your clipboard.

Note that you don't need the normal "!!" at the end of the search string to specify that SearchLink should just return the URL, that's included in the script.

View the Script