BEGIN { FS="[\", \r]" preamble="XWin -screen 0 " postamble=" -fullscreen -terminate -nowinkill -unixkill" \ " -emulate3buttons 50 -broadcast" ipaddr="" print "@echo off" print "echo Stage two started successfully" } /Resolution/ { h=$4; v=$5; print "echo Width: " h " (from " $0 ")"; print "echo Height: " v " (from " $0 ")" } /BitsPerPixel/ || /BitsPerPel/ { bpp=$4; print "echo Colour Depth: " bpp " (from " $0 ")" } /IP Address/ && ! /0\.0\.0\.0/ { ipaddr=" -from " $12 " "; print "echo IP Address: " $12 " (from " $0 ")"; } END { startcmd = preamble h "x" v "x" bpp ipaddr postamble print "echo X server start command is \"" startcmd "\"" print "echo Starting up X server. Please wait..." print startcmd print "if not errorlevel 1 exit" print "echo ." print "echo . There was an error in starting up the X server." }