Jump to content

Very amateur and simple script question


Recommended Posts

Hey guys,

I'm creating a workflow that will search a (guitar tab database) website for the current song you are listening to iTunes.

Unfortunately, I am very amateur with scripts. I hadn't really looked at one until today!

I have a script that copies the song name and artist to my clipboard (using the line "set the clipboard to (nom & art)") however, I was wondering how you can get it instead to set "nom & art" to the query for the next step of the workflow?

I know this is incredibly amateur, but thanks in advance for the help!

Ned

Link to post

Hey guys,

I'm creating a workflow that will search a (guitar tab database) website for the current song you are listening to iTunes.

Unfortunately, I am very amateur with scripts. I hadn't really looked at one until today!

I have a script that copies the song name and artist to my clipboard (using the line "set the clipboard to (nom & art)") however, I was wondering how you can get it instead to set "nom & art" to the query for the next step of the workflow?

I know this is incredibly amateur, but thanks in advance for the help!

Ned

 

Ned, have you taken a look at this post? This details how to string multiple script filters together. If you aren't using a script filter, the same principle applies. What you do is, use AppleScript to call Alfred back up. At the end of workflow execution, use the Run Script output item, with the language set to /usr/bin/osascript to:

tell application "Alfred 2" to search "<your text here>"

 

Replace <your text here> with the next command and text that you want to pass to it.

Link to post

Ned, have you taken a look at this post? This details how to string multiple script filters together. If you aren't using a script filter, the same principle applies. What you do is, use AppleScript to call Alfred back up. At the end of workflow execution, use the Run Script output item, with the language set to /usr/bin/osascript to:

tell application "Alfred 2" to "<your text here>"

 

Replace <your text here> with the next command and text that you want to pass to it.

 

 

Hi David. Don’t you mean tell Alfred to search?

 

tell application "Alfred 2" to search "<your text here>"
Link to post

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...