Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

printz

macrumors regular
Original poster
Dec 23, 2012
218
0
I'm using an Automator application menu service that spawns a new Terminal window and I've assigned a shortcut to it (control+alt+t). In most applications it works, but not in certain text editors like TextEdit or Smultron 5. I tried other control-based shortcuts, but neither those worked. Control+alt+t in particular even inserted invisible characters in the text! What gives? Can I bind some other keys while in text editors or am I out of luck?
 

benwiggy

macrumors 68020
Jun 15, 2012
2,382
201
Services usually act upon the current selection. Their availability in the Services menu depends on what the current selected objects are.

For instance, in the Finder, there is already a service that creates a new Terminal window with the working directory of the currently selected folder. (in Lion and above.)

What does your service do that other ways of creating a new Terminal window does not?

Without seeing the Automator actions/script, it's hard to say more about why it isn't working.
 
Last edited:

printz

macrumors regular
Original poster
Dec 23, 2012
218
0
For instance, in the Finder, there is already a service that creates a new Terminal window with the working directory of the currently selected folder. (in Lion and above.)

There is? Where do I find it? Most of the time the Services submenu from Finder is empty. I had to write an AppleScript and package it into an app that's pinned to the Finder toolbar. It works great.

Regarding my service that I can't reliably bind a key shortcut to, it's an Automator unit that works on any application, receives no input, and all it does is run this AppleScript:
Code:
on run {input, parameters}
	
	(* Your script goes here *)
	tell application "Terminal"
		do script " "
		activate
	end tell
	return input
end run
On all applications, the service is visible from the submenu and works if clicked. On those where the keyboard shortcut works, the shortcut is also visible on the submenu. Of course maybe if i find another key combo it will eventually work, but it would be lovely to bypass this limitation, if possible.
 

benwiggy

macrumors 68020
Jun 15, 2012
2,382
201
There is? Where do I find it?
System Preference > Keyboard > Keyboard Shortcuts > Services: "New Terminal at Folder".
I think it's unchecked by default. Just tick the box and it will be active.

If your Service is showing, but the key shortcut is missing, then perhaps the applications are using that combination and taking priority.

You can always just right-click on the Terminal icon in the Dock to create a new Terminal window. If you're looking for a keyboard command for that sort of thing (and others), then you might want to try iKey or Keyboard Maestro.
 

printz

macrumors regular
Original poster
Dec 23, 2012
218
0
System Preference > Keyboard > Keyboard Shortcuts > Services: "New Terminal at Folder".

Awesome! Didn't know OS X has it already (I thought I had to work to have it :) )

EDIT: oh, i only see some folder-triggered services, and my Finder-pinned AppleScript works good enough anyway. I guess I can just right-click the dock icon if I'm not on fullscreen, or use Spotlight.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.