keyboard-maestro-safari

My Safari Set Up

I am a big fan of single key shortcuts (originally introduced by Opera when it was at its peak before they had a brain freeze and messed it up with ads inside the browser) and in this post, I am going to share how I set them and more using Vimari, Keyboard Maestro, BetterTouchTool (available on Setapp) and other extensions in Safari on my Mac.

ShortcutWhat it does
tnew tab
cclose tab
zgo back
xgo forward
aprev tab
snext tab
rreload
⌘istart element selection (begin inspecting)
F12toggle web inspector (Dev tools)
⌘⇧Rhard refresh
F4show tab overview
F2toggle sidebar
⌘⌥←prev tab
⌘⌥→next tab
3-finger tap (trackpad)copy url
3-finger click (trackpad)add to reading list

Also have these set up for trackpad but don’t use them often:

ShortcutWhat it does
1 Finger Tap Bottom Leftprev tab
1 Finger Tap Bottom Rightnext tab
1 Finger Tap Top Leftclose tab
1 Finger Tap Top Rightnew tab
1 Finger Tap Top Middlefocus address bar
3 Finger Swipe Leftprev tab
3 Finger Swipe Rightnext tab

Vimari

Vimari is the only actively maintained port of Vimium for Safari.

This is what makes the single key shortcuts possible.

Here’s my config file:

{
  "excludedUrls": "ct_builder=true",
  "linkHintCharacters": "asdfjklqwerzxc",
  "detectByCursorStyle": false,
  "scrollSize": 150,
  "openTabUrl": "topsites://",
  "modifier": "",
  "smoothScroll": true,
  "scrollDuration": 25,
  "transparentBindings": true,
  "bindings": {
      "hintToggle": "f",
      "newTabHintToggle": "shift+f",
      "scrollUp": "k",
      "scrollDown": "j",
      "scrollLeft": "h",
      "scrollRight": "l",
      "scrollUpHalfPage": "u",
      "scrollDownHalfPage": "d",
      "goToPageTop": "g g",
      "goToPageBottom": "shift+g",
      "goToFirstInput": "g i",
      "goBack": "z",
      "goForward": "x",
      "reload": "r",
      "tabForward": "s",
      "tabBack": "a",
      "closeTab": "c",
      "openTab": "t"	
  }
}

The primary goal of Vimimum (and Vimari) though is typing a key and following links on the page by typing the hints.

To click a link on a page, I press f (f to follow links) and Vimari shows link hints like this:

If I want to read the Facebook article in the above screenshot, I simply type DS or FS as shown on that link.

Keyboard Maestro

Here’s an export file of all the above macros. Mirror.

BetterTouchTool

Here’s an export file of Trackpad gestures for Safari. Mirror.

Extensions

  • 1Password: the best password manager there is.
  • Bitwarden: I use this for storing not-so important/temporary passwords.
  • Clean Links: removes tracking junk from URLs.
  • Grammarly: keeps my English in check.
  • Notion Web Clipper: say hello to my personal information manager.
  • Octotree: makes it easier to navigate Github repos.
  • Select Like A Boss: lets me select text inside links.
  • SponsorBlock for YouTube: skips sponsor-related portions in YT videos.
  • Wipr: blocks ads, trackers, cryptocurrency miners, EU cookie and GDPR notices, and other annoyances. I also have AdGuard running system-wide. I do not remember what ads looks like anymore.

Alfred

I have Alfred set to index Safari’s bookmarks so I can quickly ⌘+Space, type where I want to go and return.

1 comment

Leave a Reply

Your email address will not be published. Required fields are marked *