Minor: add a small delay to the AppleScript that opens new terminal tabs to hack around the fact that AppleScript is racy when used this way :(

This commit is contained in:
Mike Hearn 2016-11-17 18:00:45 +01:00
parent 6240ba48e1
commit 1a9cbf91c3

View File

@ -14,6 +14,7 @@ if which osascript >/dev/null; then
if [ -d $dir ]; then if [ -d $dir ]; then
script="$script script="$script
tell application \"System Events\" to tell process \"Terminal\" to keystroke \"t\" using command down tell application \"System Events\" to tell process \"Terminal\" to keystroke \"t\" using command down
delay 0.5
do script \"cd $rootdir/$dir; java -jar JAR_NAME; exit\" in window 1" do script \"cd $rootdir/$dir; java -jar JAR_NAME; exit\" in window 1"
first=false first=false
fi fi