update for why we sleep

This commit is contained in:
Jesse Andrews 2011-11-07 09:51:15 -08:00
parent dca89009f5
commit f0b41f3fb7

View file

@ -908,7 +908,10 @@ function screen_it {
NL=`echo -ne '\015'`
if [[ "$ENABLED_SERVICES" =~ "$1" ]]; then
screen -S stack -X screen -t $1
sleep 0.5
# sleep to allow bash to be ready to be send the command - we are
# creating a new window in screen and then sends characters, so if
# bash isn't running by the time we send the command, nothing happens
sleep 1
screen -S stack -p $1 -X stuff "$2$NL"
fi
}