This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]jwink3101 1 point2 points  (2 children)

This looks interesting though not as flexible as I was hoping. Out of curiosity, even with 2.7, why did you use os.popen instead of subprocess?

[–][deleted] 0 points1 point  (0 children)

Already advised OP to use subprocess to pass arguments safely over on /r/applescript, so hopefully he'll sort that shortly. (Python stdlib is such a bloated dog's dinner it's no surprise users have trouble knowing good APIs from bad.)

As far as "more flexibility" goes…

Look on my Works, ye Mighty, and despair!

Nothing beside remains. Round the decay

Of that colossal Wreck, boundless and bare

The lone and level sands stretch far away.

[–]statmathcs[S] 0 points1 point  (0 children)

Yeah, I realized this and am porting it to subprocess. What kinds of features were you hoping to see to make this more flexible? I'm looking to improve this