-
1. Re: execute command in command line.
Gonterman1201 Jun 17, 2014 8:02 AM (in response to Gonterman1201)I tried making an executable like this
app.system("/Users/bagonterman/Desktop/MongoData.sh");but it does nothing. In the toolkit it says that system runs just like command line. So how is this not running?
-
2. Re: Re: execute command in command line.
Gonterman1201 Jun 17, 2014 8:20 AM (in response to Gonterman1201)I also tried this
app.system("osascript do shell script '/Users/bagonterman/Desktop/MongoData.sh'"); -
3. Re: execute command in command line.
d1g1talphyre Jul 16, 2014 2:45 PM (in response to Gonterman1201)BUMP!
I figured it out. Let me walk you through so you understand. I've been having the same issues you have been having here.
So at first I tried what you were trying to no avail. Then I tried this...
poo = "find /Volumes/IllustratedUses -iname '" + DocumentID + "' | xargs -I '{}' cp {} /Volumes/Archive_ME/tempDir/and behold, it worked. I was shocked. So I tried running a python script. wa wa waaaa, nothing.
I went and talked to a buddy in our photo studio who is really good with bash on mac. He said check your enviroment.
The trick is to manually set your path variables in the line of code you want to run.
poop = "PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin; cd /Volumes/Archive_Me/tempDir/; sh illuse.sh" app.system(poop)
and my friend that worked. I hope this helps other people in the future.

