$ SWG__QUIET = %x10000000 ! Inhibit display (bit 28) $ SWG__SUCCESS = SWG__QUIET + %x0001 ! Severity 1 (success) $ SWG__FATAL = SWG__QUIET + %x0004 ! Severity 4 (fatal error) $ SWG__CONTROLY = SWG__FATAL $ on warning then exit SWG__FATAL $ on control_y then exit SWG__CONTROLY $ if f$type(SWG__QUIET) .eqs. "" then exit %x10000000 $! $! P1 = "-TASK" is used by the WING main executable to launch a task $! $ if P1 .eqs. "-TASK" then goto WINGTASK $ if P1 .eqs. "-SLOW" $ then $ WING_SLOW == "1" $ P1 = P2 $ endif $ define/nolog/job WING$PRINT sprint $ wingexe0 = "$ $EXE:WING" $ WING_HOME = f$environment("DEFAULT") $ if P1 .nes. "" $ then $ fd 'P1 $ wingexe = wingexe0+"/start="+f$environment("default") $ else $ wingexe = wingexe0 $ endif $! $! Copy global symbols to local symbols. Then delete the global symbols $! $ if f$type(WING_FILER) .nes. "" $ then $ WING_FILER = WING_FILER $ delete/symbol/global WING_FILER $ WING_DISK = WING_DISK $ delete/symbol/global WING_DISK $ WING_AVO = WING_AVO $ delete/symbol/global WING_AVO $ WING_SPEC = WING_SPEC $ delete/symbol/global WING_SPEC $ WING_NAME = WING_NAME $ delete/symbol/global WING_NAME $ else $ WING_FILER = " " $ WING_DISK = " " $ WING_AVO = "0" $ WING_SPEC = " " $ WING_NAME = " " $ endif $ WING_LOOP = "" $ set noon $ MORE_WINGING: $ if WING_DISK .nes. " " $ then $ cd 'WING_DISK $ if $STATUS $ then $ wingexe = wingexe0+"/start="+f$environment("default") $ WING_FILER = "0" $ else $ echo LIB__ANS S " Hit any key to continue" ENTER U $ endif $ WING_DISK = " " $ else $ wingexe = wingexe0 $ endif $ define/user_mode SYS$INPUT LIB$ECHO $ wingexe $ if WING_LOOP .nes. "" $ then $ WING_FILER == WING_FILER $ WING_DISK == WING_DISK $ WING_AVO == WING_AVO $ WING_SPEC == WING_SPEC $ WING_NAME == WING_NAME $ else $ if WING_FILER .nes. "" then goto MORE_WINGING $ endif $ set on $ undefine/job WING$PRINT $ cd 'WING_HOME $ exit SWG__SUCCESS ! $ WINGTASK: $ on warning then goto TASK_ERROR $ on control_y then goto TASK_ERROR $! $ CurrentDir = f$environment("DEFAULT") $! $ if P2 .eqs. "" $ then $ signal WINGTASK W NOFILSPEC "no file or command specified" $ goto TASK_EXIT $ endif $! $ if P2 .eqs. "WINGLOOP" $ then $ signal WINGTASK I WINGLOOP "started active wingloop" $ exit SWG__SUCCESS $ endif $! $ RRRUN = "''P2' ''P3' ''P4' ''P5' ''P6' ''P7' ''P8'" $ TASKTODO = f$search(P2) $ if TASKTODO .nes. "" then goto TASK_FILE $! $ say " Executing command : ",RRRUN $ THISDEV = f$trnlnm("SYS$INPUT") $ define/user_mode/nolog SYS$INPUT LIB$ECHO $ 'RRRUN $! $ goto TASK_EXIT $! $ TASK_FILE: $ TASKTYPE = f$parse(TASKTODO,,,"TYPE") $ if TASKTYPE .nes. ".COM" .and. - TASKTYPE .nes. ".EXE" .and. - TASKTYPE .nes. ".PLAY" $ then $ signal WINGTASK W EXECOMFIL "not a .COM or .EXE file, ''P2'" $ goto TASK_EXIT $ endif $ say " Executing file ",RRRUN $ if TASKTYPE .eqs. ".EXE" $ then $ RRRUN = "$ "+RRRUN $ define/user_mode SYS$INPUT LIB$ECHO $ RRRUN $ endif $ if TASKTYPE .eqs. ".COM" $ then $ RRRUN = "@ "+RRRUN $ define/user_mode SYS$INPUT LIB$ECHO $ RRRUN $ endif $ if TASKTYPE .eqs. ".PLAY" $ then $ RRRUN = "''play' "+RRRUN $ RRRUN $ endif $ TASK_EXIT: $ set default 'CurrentDir $ exit SWG__SUCCESS $! $ TASK_ERROR: $ STATUS = $STATUS $ set default 'CurrentDir $ echo LIB__ANS S " ERROR ''STATUS' .... " CONTINUE $ exit STATUS