5 ' SIMCVT.BAS: TRANSFORM THE SIMIBM.IDX FILE FROM SIMTEL20 INTO A
6 ' READABLE FORM, AND CALL IT SIMIBM.LST.
10 OPEN "SIMIBM.IDX" FOR INPUT AS #1
20 OPEN "SIMIBM.LST" FOR OUTPUT AS #2
22 PRINT #2, "WSMR-SIMTEL20.ARMY.MIL PUBLIC DOMAIN LISTING AS OF "; DATE$
23 PRINT #2,
25 PRINT #2, "NOTE: Type B is Binary; Type A is ASCII"
80 WHILE NOT EOF(1)
100   INPUT #1, FS$, DIR$, FLNM$, REV, LNGTH, BITS, DT, DESCR$
105   IF FS$<>LFS$ OR DIR$<>LDIR$ THEN GOSUB 500
110   PRINT #2, FLNM$; TAB(15);
115   IF BITS=8 THEN PRINT #2, "B"; ELSE PRINT #2, "A";
120   PRINT #2, USING " ####### ####### &"; LNGTH, DT, " "+DESCR$
127   LFS$ = FS$: LDIR$ = DIR$
130 WEND
150 CLOSE #1
160 CLOSE #2
165 SYSTEM
170 END
500 REM New Directory
510 PRINT #2,: PRINT #2, "Directory ";FS$;DIR$
530 PRINT #2, " Filename   Type Length   Date    Description"
540 PRINT #2, "=============================================="
560 RETURN
