@echo off
if not "%1" == "/*" goto aa
if "%2" == "..1.12" goto us1
cls
:usage
echo - For use with FWKCS(TM) Contents_Signature System, Version 1.12.
echo - (C)Copyright Frederick W. Kantor 1991. All rights reserved.
echo -
:us1
echo - REVCSL.BAT to REVise cslist.ndx, cslist.srt, cslist1.ndx, cslist1.srt,
echo -            on a system with no overlapping paths, any/all drives C: - Z:,
echo -            searching for non_directory files,
echo -            preserving all prior unique contents_signatures on system,
echo -            deleting obsolete d:\path specification(s).
echo -
echo - You must be in your \cs subdirectory to use this program. (see SETUP.112)
echo -
echo - Usage:
echo -
echo -      REVCSL n "<enter>"
echo -
echo - n = 1 include only zipfiles with extension(s) .Z*.
echo -     2 include only zipfiles, any or no extension, self_extracting or not.
echo -     3 include all accessible non_directory files.
goto ng
:aa
cls
if not exist cslist.srt goto help1
if "%1" == "1" goto ab
if "%1" == "2" goto ab
if "%1" == "3" goto ab
goto help2
:ab
if exist #@!#@!^^.@!@ attrib -r #@!#@!^^.@!@ > nul
if exist #@!#@!^^.@!@ del #@!#@!^^.@!@ > nul
if exist @@!#@!^^.@!@ attrib -r @@!#@!^^.@!@ > nul
if exist @@!#@!^^.@!@ del @@!#@!^^.@!@ > nul
echo sort test > #@!#@!^^.@!@
qsort #@!#@!^^.@!@ @@!#@!^^.@!@ > nul
del #@!#@!^^.@!@ > nul
if not exist @@!#@!^^.@!@ goto nsrt
cls
del @@!#@!^^.@!@ > nul
fwkcs /v
if exist cslist.ndx attrib -r cslist.ndx
attrib -r cslist.srt
del cslist1.srt > nul
ren cslist.srt cslist1.srt
if "%1" == "2" goto bb
if "%1" == "3" goto bc
fwkdg /l | find ".Z" | fwkcs /1cfxz | qsort > cslist.srt
goto cc
:bb
fwkdg /l | fwkcs /1cfxz | qsort > cslist.srt
goto cc
:bc
fwkdg /l | fwkcs /1cfpxz | qsort > cslist.srt
:cc
fwkcs /vs
goto end1
:nsrt
echo -
echo - Where is Ben Baker's QSORT?
goto helpr
:help1
echo -
echo -   Did not find CSLIST.SRT.
echo -
echo -   Please see SETUP.112, and then
goto helpr
:help2
echo - I need a digit n (1 2 3) re files to include.
:helpr
echo -
echo -           Please try again.
echo -
goto usage
:end1
echo -
echo -  Revised cslist.ndx, cslist.srt, cslist1.ndx, and cslist1.srt,
if "%1" == "2" goto dc
if "%1" == "3" goto dd
echo -    based on searching only new zipfiles with  .Z*  extensions,
goto ee
:dc
echo -    based on searching only new zipfiles with any or no extension,
goto ee
:dd
echo -    based on searching all accessible non_directory files,
:ee
echo -    preserving all prior unique contents_signatures on system,
echo -    deleting obsolete d:\path specification(s).
:ng
echo -
if not "%2" == "..1.12" goto zz
if exist QUERYFLA.GUP attrib -r QUERYFLA.GUP > nul
if exist QUERYFLA.GUP del QUERYFLA.GUP > nul
:zz
