How do you use the script? Are you running it from the script editor? Have you saved it as an application?
You should be able to save it as an application. When saving, select Application from the pop up menu. Do not check the little box that says "stay open". It should execute then terminate.
How do you use the script? Are you running it from the script editor? Have you saved it as an application?
You should be able to save it as an application. When saving, select Application from the pop up menu. Do not check the little box that says "stay open". It should execute then terminate.
i did such thing but it does not terminate. it stays open and i have to force quit it.
It may give you some ideas. I don't use shell scripts but the first part of the document made me think of possible ways the shell script could be getting confused. Hope it helps.
Comments
quit
end tell
Originally posted by DMBand0026
Tell application "X11"
quit
end tell
nono
I want the actual applescript to quit
You should be able to save it as an application. When saving, select Application from the pop up menu. Do not check the little box that says "stay open". It should execute then terminate.
Originally posted by neutrino23
How do you use the script? Are you running it from the script editor? Have you saved it as an application?
You should be able to save it as an application. When saving, select Application from the pop up menu. Do not check the little box that says "stay open". It should execute then terminate.
i did such thing but it does not terminate. it stays open and i have to force quit it.
any ideas?
Originally posted by soulcrusher
i did such thing but it does not terminate. it stays open and i have to force quit it.
any ideas?
tell application "X11" to activate
do shell script "DISPLAY=:0.0 /opt/local/bin/gimp &"
end tell
Is that right?
If the script gets as far as the "end tell" statement then it should terminate. This makes me think that somehow it is hanging in the shell script.
I did a quick google search on "AppleScript" and "Shell Script" and "how" and found this developers note.
http://developer.apple.com/technotes/tn2002/tn2065.html
It may give you some ideas. I don't use shell scripts but the first part of the document made me think of possible ways the shell script could be getting confused. Hope it helps.