Jump to content

avclark

Member
  • Posts

    8
  • Joined

  • Last visited

Posts posted by avclark

  1. Hey @deanishe I was attempting to go with what appears to be the preferred way and save my script as a file and just call it from within an run script action. The problem is none of my arguments/variables are being passed to the script... The script works fine, but it just ignores the q1 and q2.

     

    Here's what my new run script looks like. All the iTerm stuff from before has been abstracted to ht.applescript.

     

    5a7d1e29c93b9_ScreenShot2018-02-08at11_04_12PM.png.3d5fe3ecba7de19e5e2b3d56c16ab5a8.png

     

    Thanks in advance for the help man!

     

  2. That's awesome. That's so simple. How do I learn more about this? Like, I would never have reasoned my way to that conclusion. Is there documentation somewhere?

     

    Specifically, I'm talking about "theWords", "item 1", "word 1", etc... Is that specific to AppleScript or is that specific to Alfred? Just trying to narrow my search to learn more about this stuff...

     

    Thanks again. 

  3. Thanks. That totally makes sense. I'm sure I'm using the wrong terminology. The thing I'm uncertain of is how to get from Keyword, to AppleScript, where I would use write:

    set x to word 1 of “{query}”

    set y to word 2 of “{query}”

     

    I'm new to Alfred 3, so I'm still trying to figure out the Args and Vars. For example, I read through this post:

     

     

    and one of the replies used this graphic (red highlighting is mine):

     

    cTStr6Z.thumb.png.3a9a3464045999241425fc1aa81efba4.png

     

    What is going on in the "store input in var project"? What information do I put into the Args and Vars utility to make that happen? 

     

    I hope that makes sense. 

     

    I would post my workflow, but it doesn't really exist yet. All I have is the Keyword at the beginning and the Run NSAppleScript at the end. My AppleScript is complete and works with one argument. I'm just not sure about the middle part and how to split and store the argument so that my script can use them. 

     

    In case I'm not making sense, here's a pseudo code version of what I'm trying to do:

     

    Keyword project1^^project2 -> split "project1^^project2" into "project1" and "project2" -> do something in AppleScript with "project1" and "project2" separately, rather than just "project1^^project2" as it is now.

     

    Hope that makes more sense. 

     

    Thanks.

  4. Thanks in advance for the help!

     

    I'm trying to pass two (or multiple) variables to AppleScript. For example, “keyword query1 query2” and then get both arguments into AppleScript. Or something like “keyword query1^query2” and then split them. I feel like I’m almost there, but missing something… I guess I should add that I’m using Alfred 3.5.1 with Powerpack. I read this article:

     

     

    but my dumb brain couldn’t figure it out… ;) Any help would be greatly appreciated. My use case for this particular workflow is AppleScipt, but I'd be interested in knowing how to do the same thing with a bash script or something like that. 

     

    Thanks!

×
×
  • Create New...