1 EDIT You can invoke TECO with the standard DCL EDIT command by specifying the /TECO qualifier. Formats EDIT/TECO file-spec to edit an existing file EDIT/TECO file-spec/OUTPUT=new-file to edit from one file to another EDIT/TECO file-spec/CREATE to create a new file EDIT/TECO/EXECUTE=cmd-file-spec to execute a TECO command file EDIT/TECO/EXECUTE=cmd-file-spec text as above, but passes a text argument in the text buffer 2 Initialization If TECO finds the logical name TEC$INIT, its equivalence string is assumed to be either a TECO macro or, if the string starts with a dollar sign ($), the rest of the string is assumed to be a file-spec containing a TECO macro to be executed every start up. To disable the lookup of TEC$INIT, the qualifier /NOCOMMAND can be used. To explicitly specify a start up TECO macro file, the qualifier /COMMAND=file-spec can be used. 3 Actions Your initialization TECO macro can request the following actions by returning a bit encoded numeric value. 1 => Load and start up VTEDIT.TEC (scope editing macro) 2 => Only inspect specified file (/READ_ONLY) 4 => Inhibit TECO's memory (/NOMEMORY) 8 => Position to VTEDIT's position marker 16 => Enable scope editing SEEALL mode (-1,3:W) 32 => Enable scope editing HOLD screen mode (-1,5:W) 128 => Enable scope editing scroll mode (2:W/4,7:W) 256 => Inhibit automatic file creation (/NOCREATE) 4096 => Initialization is complete 8192 => Force TECO to update TECO's memory 16384 => Display file being edited 32768 => Initialization used TECO's memory; TECO shouldn't 3 Conditions When the initialization TECO macro is executed, the following conditions are in effect. Text buffer User's editing command Q-register 0 Initialization TECO macro itself Q-register 9 TECO's built-in command decoder data storage Q-register Y TECO's built-in command decoder TECO macro The user's editing command in the text buffer can be modified by the initialization TECO macro. All other Q-registers are initially scratch and can be used or loaded by the initialization TECO macro; their contents will subsequently be preserved. 3 Example The following initialization TECO macro always disallows automatic file creation (256) and, for scope terminals only (512 in ET), enables scope editing scroll mode (128) in SEEALL mode (16) with immediate mode command output turned off (-1EV). 256U0 ET&512"N Q0#128#16U0 -1EV ' Q0#4096 This initialization TECO macro would be defined as the equivalence string to the logical TEC$INIT as follows. $ DEFINE TEC$INIT "256U0 ET&512""N Q0#128#16U0 -1EV ' Q0#4096" 2 Defaults Your LOGIN.COM file can define an EDIT/TECO command with preset qualifiers if desired. The qualifiers /NOCOMMAND, /NOCREATE, and /NOMEMORY are always recognized so that they can be preset at command definition time. To disable all TECO start up actions you would use TECO == "EDIT/TECO/NOCOMMAND/NOCREATE/NOMEMORY" To disable only TECO's memory you would use TECO == "EDIT/TECO/NOMEMORY" Etc. 2 Memory TECO automatically remembers the file being edited. The file's name is stored in a process logical called TEC$MEMORY. If you invoke TECO without specifying a file-spec, TECO will read its memory logical and re-edit the last edited file. TECO's memory feature is completely inhibited by the /NOMEMORY qualifier. 2 Qualifiers /COMMAND /COMMAND, the default, will use the start up TECO macro described by the logical TEC$INIT, if any. /COMMAND=file-spec will use the start up TECO macro in the specified file. /NOCOMMAND completely inhibits any special start up actions. /CREATE /CREATE, the default, will cause a new file to be created if the specified editing file doesn't exist. /NOCREATE inhibits any automatic file creation. /EXECUTE /EXECUTE=file-spec causes the specified TECO macro file to be executed. /MEMORY /MEMORY, the default, will utilize TECO's memory logical TEC$MEMORY. /NOMEMORY competely inhibits TECO's memory feature. /OUTPUT /OUTPUT=file-spec will cause the edited file to be written into the specified file-spec instead of creating the next higher version of the same file. /READ_ONLY /READ_ONLY will cause the specified editing file to be only read; no output file will be created.