ENH: Change permission for getdisplay.sh to make the runtimescript work

This commit is contained in:
Andy Cedilnik 2007-01-10 18:33:03 -05:00
parent de5540f7e5
commit f015e1ff03
1 changed files with 6 additions and 1 deletions

View File

@ -22,12 +22,17 @@ else
echo \$DISPLAY > "$TMP/display"
fi
__END_OF_GETDISPLAY_SCRIPT__
chmod +x "$TMP/getdisplay.sh"
rm -f $TMP/display
open-x11 $TMP/getdisplay.sh || \
open -a XDarwin $TMP/getdisplay.sh || \
echo ":0" > $TMP/display
while [ "$?" == "0" -a ! -f $TMP/display ]; do sleep 1; done
while [ "$?" == "0" -a ! -f $TMP/display ];
do
#echo "Waiting for display $TMP/display"
sleep 1;
done
export "DISPLAY=`cat $TMP/display`"
ps -wx -ocommand | grep -e '[X]11' > /dev/null || exit 11