home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 9
/
FreshFishVol9-CD2.bin
/
bbs
/
util
/
dosk-1.0.lha
/
DosK
/
Commands
/
DeleteK
< prev
next >
Wrap
Text File
|
1995-01-04
|
3KB
|
95 lines
FAILAT 21
PROMPT %S >ENV:PMT
LAB START
IF $BKUP EQ "1"
ECHO " "
ECHO " "
ECHO "SINGLE FILE DELETE MODE BACKUP ACTIVE"
ELSE
ECHO " "
ECHO " "
ECHO "BE CAREFUL!!! BACKUP IS OFF"
ENDIF
REQUESTCHOICE >ENV:FDEL "DeleteK ©December 1994 By Kenneth J. McCormick. All Rights Reserved." "Pick A Delete Mode" "DELETE" "ALL" "FORCE" "BACKUP" "EMPTY DIR" "BYE"
IF $FDEL EQ "0"
SKIP DONE
ENDIF
IF $FDEL EQ "1"
REQUESTFILE >ENV:FILE TITLE="PICK A FILE TO DELETE"
REQUESTCHOICE >ENV:DF "DeleteK" "Delete File" "YES" "NO WAY"
IF $DF EQ "1"
IF $BKUP EQ "1"
COPY $FILE TO RAM:
DELETE $FILE
SKIP OUT1
ENDIF
DELETE $FILE
ENDIF
ENDIF
LAB OUT1
IF $FDEL EQ "2"
REQUESTFILE >ENV:FILE TITLE="PICK A DIRECTORY TO DELETE CONTENTS OF" DRAWERSONLY
cd $file
$PMT >ram:temp_K4
ECHO >RAM:TEMP_K3 "WARNING ALL FILES WILL BE DELETED IN:"
JOIN RAM:TEMP_K3 RAM:TEMP_K4 AS RAM:TEMP_K5
TYPE RAM:TEMP_K5
REQUESTCHOICE >ENV:DF "DeleteK" "Delete CONTENTS of Directory" "YES" "NO WAY"
IF $DF EQ "0"
SKIP START BACK
ENDIF
DELETE $FILE ALL
ENDIF
;FORCE AREA ==============================
IF $FDEL EQ "3"
REQUESTCHOICE >ENV:TYPE TITLE="DeleteK" "FORCE DELETE " "FILE" "DIRECTORY" "ABORT"
IF $TYPE EQ "0"
SKIP START BACK
ENDIF
IF $TYPE EQ "1"
REQUESTFILE >ENV:FILE TITLE="PICK A FILE TO DELETE"
REQUESTCHOICE >ENV:DF "DeleteK" "FORCE Delete File" "YES" "NO WAY"
IF $DF EQ "1"
IF $BKUP EQ "1"
COPY $FILE TO RAM:
DELETE $FILE FORCE
SKIP START BACK
ENDIF
DELETE $FILE FORCE
ENDIF
ENDIF
IF $TYPE EQ "2"
REQUESTFILE >ENV:FILE TITLE="PICK A DIRECTORY TO DELETE CONTENTS OF" DRAWERSONLY
cd $file
$PMT >ram:temp_K4
ECHO >RAM:TEMP_K3 "WARNING ALL FILES WILL BE FORCE DELETED IN:"
JOIN RAM:TEMP_K3 RAM:TEMP_K4 AS RAM:TEMP_K5
TYPE RAM:TEMP_K5
REQUESTCHOICE >ENV:DF "DeleteK" "FORCE Delete CONTENTS of Directory" "YES" "NO WAY"
IF $DF EQ "0"
SKIP START BACK
ENDIF
DELETE $FILE ALL FORCE
ENDIF
ENDIF
;END FORCE AREA =========================
IF $FDEL EQ "4"
UNSET BKUP
REQUESTCHOICE >ENV:BKUP "DeleteK" "Turn Backup" "ON" "OFF"
ENDIF
IF $FDEL EQ "5"
REQUESTFILE >ENV:FILE TITLE="PICK A EMPTY DIRECTORY TO DELETE" DRAWERSONLY
REQUESTCHOICE >ENV:DF "DeleteK" "Delete EMPTY Directory" "YES" "NO WAY"
DELETE $FILE
ENDIF
SKIP START BACK
LAB DONE
cd ram:
DELETE TEMP_K#? quiet
UNSETENV BKUP
UNSETENV FDEL
UNSETENV FILE
UNSETENV TYPE
UNSETENV PMT
PROMPT "%N.%S"