File: RTOUT.TE of Disk: Disks/PDP8-Net/multos8
(Source file text) 

J:S."FZJ@I/.DI/! Force .DI ext
!HXA! name into Q-reg. A
!HKGY!get macro!J2SFILE-4DGA! insert file name
!J2SSTART!0,.K! remove setup
!!START!^AEnter desired extension:!
!!INLOOP!^TI-1A-13"EOENDIN'! ext done
!-1A-127"E!rubout!.-1"NRD.-1,.TRD'OINLOOP'!delete it
!OINLOOP! not special
-DHXA! store ext in Q-reg. A
!HKEnter input device name:!
!!DEVLOOP!^TI-1A-13"EOALLDONE'! device dOne.
!-1A-127"E!rub!.-1"NRD.-1,.TRD'ODEVLOOP' !echo deleted and loop
!ODEVLOOP! leave this in buffer
-DHXG! store device name
!HKERFILE!open input file!EWTECBAT.TM!open batch stream output
!2UF!Set up line ctr!@I/$JOB
/!MORE!A! get input & count lines
!1UB!   line counter
!-L:S."FQEJKOENDPACK'! a valid line has a . (before ext)
!.-QC">QEJKoENDPACK'! delete lines without .'s
!QEJ.,.+6XD! put file name in Q-reg. D
!0L@I/*/GD@I/./GA! build "*name.ext"
!@I/</GG9C! insert "<" then skip name
!@I&/O&! insert /O switch
/!ENDPACK!>J<@FS/ //>J<@FS/#/ />! kill blanks
!^N"EHPWHK0UFOMORE'! work on rest of file
/EGSUB TECBAT.TM/T! close out and start batch file