Is there a way to make Alfred press 'Enter' key after workflow is done?

1

I have a simple workflow that I call on pressing CMD+D. It just calls Alfred and puts "define word_from_clipboard" in the search box. Then I have to press enter to run it. Is there a way to automate it - so I don't have to press 'Enter' key to see the results?

whitesiroi

Posted 2015-09-06T09:59:39.183

Reputation: 175

Answers

1

I think you might need to adjust your workflow. I'm using this myself to define the OS X text selection (instead of the clipboard) and I get the definitions shown right away.

Try to configure or recreate your workflow this way:

Triggers > Hotkey with Action: Show Alfred, Argument: OS X Clipboard contents, Prefix: define (include a white space after define)

If you were referring to open the dictionary right away, without showing the results in Alfred and having to press enter to view the definition on the Dictionary app, then you could do:

Triggers > Hotkey with Action: Pass through to workflow, Argument: OS X Clipboard contents, Prefix: (leave it empty)

Add and connect an Actions > Run script module with this content: open dict://"{query}"

cesalazar

Posted 2015-09-06T09:59:39.183

Reputation: 151

Aaaaah, thank you very much, you're the man. It does work flawlessly, again thank you man. – whitesiroi – 2015-09-13T05:05:38.390

3

In case we do not want to use Alfred to look the meaning of words, we can use a built-in dictionary and assign a key combo for that.

Mac System Preference

Click on the top left Apple icon and open System preference
Keyboard > Shortcuts > Services
Then assign keys cmd-control-d for the dictionary lookup

enter image description here

Usage

We can just select any word (double-click it), then press cmd-ctrl-d, it will open dictionary app and show the meaning instantly.

astro123

Posted 2015-09-06T09:59:39.183

Reputation: 173

Can you elaborate on this a little more? – Toto – 2018-05-05T20:29:30.193

@Toto I have updated the answer. – astro123 – 2018-05-05T22:18:04.463

@astro123 +1 thank you very much for your help. – whitesiroi – 2018-05-06T02:46:33.090