1

Is there a way to change the keyboard shortcut for the back button? Because there is no menu item for this, the MacOS keyboard shortcuts cannot be used.

Instead of Cmd+ (boths hands needed) I want to use Cmd+ESC (left hand only)

Update: With thanks to @sintax I installed Hammerspoon and wrote this little script to add the new shortcut. Works fine!

goBack = hs.hotkey.new({'cmd'}, 'escape', function()
  hs.eventtap.keyStroke({'cmd'}, 'left')
end)

hs.window.filter.new('Firefox')
  :subscribe(hs.window.filter.windowFocused,function() goBack:enable() end)
  :subscribe(hs.window.filter.windowUnfocused,function() goBack:disable() end)
  • The wonderful BetterTouchTool will let you add shortcuts for any menu item OR keyboard shortcut, activated by keyboard shortcut, custom gesture (per application or global) or any other trigger you can think of. I can’t praise it highly enough. – Wildcard Sep 6 at 22:16
1

Your best bet is probably writing a Hammerspoon script to provide that functionality by watching for Cmd+ESC pressed while Firefox is foregrounded and sending a WWW_BACK keycode when it sees that. Hammerspoon is like Autohotkey, but more powerful. It's scripted in Lua, which is quite straightforward to start writing.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.