Dec 162017
DELete all BUT one filespec, revised. Includes ASM source. | |||
---|---|---|---|
File Name | File Size | Zip Size | Zip Type |
DELBUT.COM | 1423 | 729 | deflated |
DELBUT2.ASM | 7406 | 2762 | deflated |
DELBUT2.DOC | 1138 | 690 | deflated |
Download File DELBUT2.ZIP Here
Contents of the DELBUT2.DOC file
DELBUT V 2.1(minor fix)by J.E. Arkay 6/07/88
Deletes all but a given filespec in one directory. Useful for managing your
RAM disk.
*** TESTED, BUT NOT VERY MUCH *** *** TRY IT ON A SCRATCH DISK FIRST ***
Syntax:[d:][\path\]DELBUT2 [d:][\path\]filename.ext
It will not delete a Hidden or Read-Only file; it can delete itself.
Its use of wildcards is now just like DOS (which sucks, but won't surprise you):
DELBUT ?????.?? matches ABCDE.12 and ABCD.12 and ABC.1 but not ABCD.123
For example, on our AT clone with extended memory, we use a DOS shell that runs
faster from a RAM disk. When we start AutoCAD or copy a 1.2 Meg floppy, we use
DELBUT in a batch file to erase the RAM disk except for the DOS shell.
You can use it in a batch file where DEL *.* would give its 'Y/N' message and
require a keypress. Example to DEL D:\MY-DIR\*.*:
create a 1-byte file named X (DOS won't copy a zero-byte file)
COPY X D:\MY-DIR
DELBUT D:\MY-DIR\X
It returns Errorlevel=1 if nothing is deleted or an error occurs.
For instructions, TYPE or edit the .COM file or run it with no command line.
Deletes all but a given filespec in one directory. Useful for managing your
RAM disk.
*** TESTED, BUT NOT VERY MUCH *** *** TRY IT ON A SCRATCH DISK FIRST ***
Syntax:[d:][\path\]DELBUT2 [d:][\path\]filename.ext
It will not delete a Hidden or Read-Only file; it can delete itself.
Its use of wildcards is now just like DOS (which sucks, but won't surprise you):
DELBUT ?????.?? matches ABCDE.12 and ABCD.12 and ABC.1 but not ABCD.123
For example, on our AT clone with extended memory, we use a DOS shell that runs
faster from a RAM disk. When we start AutoCAD or copy a 1.2 Meg floppy, we use
DELBUT in a batch file to erase the RAM disk except for the DOS shell.
You can use it in a batch file where DEL *.* would give its 'Y/N' message and
require a keypress. Example to DEL D:\MY-DIR\*.*:
create a 1-byte file named X (DOS won't copy a zero-byte file)
COPY X D:\MY-DIR
DELBUT D:\MY-DIR\X
It returns Errorlevel=1 if nothing is deleted or an error occurs.
For instructions, TYPE or edit the .COM file or run it with no command line.
December 16, 2017
Add comments