Is there a way to get notified when the terminal has finished the command?
-> I run another script (not mine!) That loads the data, when this script is finished, I want to exit the terminal and do other things with this data.
EDIT:
I could not ask correctly ...
Example:
tell application "Terminal"
keystroke "php downloadscript.php"
keystroke return
end tell
if (downloadFinished)
-- do stuff
else
-- wait till finished
Edit 2:
Awesome! Thank! By working like this:
tell application "Terminal"
set frontWindow to window 1
repeat until busy of frontWindow is false
delay 1
end repeat
end tell
greetings hatschii
source
share