Jump to content

Search nvALT for text, and bring window to front


Recommended Posts

  • 3 months later...
  • 3 months later...
  • 2 weeks later...

I was able to successfully work around it by adding a third line to the AppleScript part of the workflow, so that it reads:

on alfred_script(q)
tell application "nvALT"
  reopen
  activate
  tell application "System Events" to keystroke "l" using command down
end tell
end alfred_script
Edited by tsigo
Link to comment
  • 1 month later...

tsigo's fix is only partially working for me on Mavericks--is it still working for others? If nvAlt is not currently open, this workflow will open nvAlt, but not insert the search string. If nvAlt is currently open, the workflow works as expected: puts the search string in the omnibar of nvalt.  Curious to hear if this is my problem, or if others are experiencing it as well.

Link to comment

tsigo's fix is only partially working for me on Mavericks--is it still working for others? If nvAlt is not currently open, this workflow will open nvAlt, but not insert the search string. If nvAlt is currently open, the workflow works as expected: puts the search string in the omnibar of nvalt.  Curious to hear if this is my problem, or if others are experiencing it as well.

 

Same issue here.

Link to comment
  • 2 weeks later...

It works perfect for me. Thanks.

 

 

Here is what I came up with - it brings nvAlt to front, focuses on input, and enters search query.

on alfred_script(q)
tell application "nvALT"
	reopen
	activate
	tell application "System Events" to keystroke "l" using command down
	tell application "System Events" to keystroke q
end tell
end alfred_script
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...