sfsdfd Posted February 13, 2016 Share Posted February 13, 2016 I've created some workflows that run Python scripts stored at some specific locations. In general, everything's going fine, but there's one thing that's bothering me a bit: I'm running them by choosing "Run Script," selecting the language as Bash, and then entering the script as "/usr/bin/python script_location script_parameters." This just seems clumsy to me because Alfred actually can call the Python interpreter directly, instead of through bash like this. The problem is simply that the "Run Script" dialog has no way to specify a location of a script: you can only specify the actual contents of the script. I don't actually want to store the Python script itself inside the workflow. Does this seem odd to anyone else? Anyone have any solutions? Link to comment
vitor Posted February 13, 2016 Share Posted February 13, 2016 (edited) Does this seem odd to anyone else? Not really, no. It’s common practice. Many (most?) workflow developers, like you, prefer to have their scripts as a file, instead of inside the Run Script dialog. deanishe (creator of a popular python library for workflows and of many workflows using python) also does it that way, if that eases your concern on the python front. It’s just like running a script from your terminal. Just instead of a terminal you’re using Run Script. Your method is fine, and most of us do it like that most of the time. Edited February 13, 2016 by Vítor Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now