.DISABLE LOWERCASE
.ENABLE ESCAPE
.ENABLE SUBSTITUTION
.;		M.R. BROWN  24-MAY-79
.;		R.E. HUGHES 29-AUG-79 added ESC
.;		M.R. Brown 24-Nov-79  added UFD deletion
.;		M.R. Brown 4-DEc-79  added file deletion
;
; THIS INDIRECT COMMAND FILE WILL CHANGE THE PROTECTION OR DELETE
; A DIRECTORY INTERACTIVLY WITHOUT HAVING TO FIGHT WITH PIP
;
; YOU MAY STOP AT ANY TIME BY TYPING ^Z
; Typing ESCAPE will leave the answer unchanged
;
.START:
	.SETS GROUP "200"
	.SETS MEMBER "200"
	.SETS NL ""
	.SETS DISK "DR0:"
	.SETS SYS "RWED"
	.SETS OWN "RWED"
	.SETS GRO "RWE"
	.SETS WOR "R"	
.ASKS DISK   Which Disk do you want to modify ['DISK']
.INPUT:
	.ASKS [1:3] GROUP WHAT IS THE GROUP  NUMBER
.IF <STRLEN> = 2 .SETS GROUP "0"+GROUP
.IF <STRLEN> = 1 .SETS GROUP "00"+GROUP
	.ASKS [1:3] MEMBER WHAT IS THE MEMBER NUMBER
.IF <STRLEN> = 2 .SETS MEMBER "0"+MEMBER
.IF <STRLEN> = 1 .SETS MEMBER "00"+MEMBER
PIP 'DISK'[0,0]'GROUP''MEMBER'.DIR/FU
.GET:
.ASKS WHAT TYPE "D" TO DELETE THIS ENTRY, "M" TO MODIFY, ^Z TO STOP
	.IF WHAT = "M" .GOTO MOD
	.IF WHAT = "" .GOTO INPUT
	.IF WHAT NE "D" .GOTO GET
.ASK CHECK Are you sure that you want to remove ['GROUP','MEMBER']
.ASK FILES Do you want all the files in ['GROUP','MEMBER'] deleted
.IFT FILES PIP 'DISK'['GROUP','MEMBER']*.*;*/de
.IFT CHECK PIP 'DISK'[0,0]'GROUP''MEMBER'.DIR;*/DE
.GOTO END
.MOD:
; 			*****  TYPE ESC FOR DEFAULT  *****
	.ASKS SYS WHAT SYSTEM PROTECTION DO YOU WANT; DEFAULT ['SYS']
	.IF SYS = "B" .GOTO START
	.ASKS OWN  WHAT OWNER PROTECTION DO YOU WANT; DEFAULT ['OWN']
	.ASKS GRO   WHAT GROUP PROTECTION DO YOU WANT; DEFAULT ['GRO']
	.ASKS WOR     WHAT WORLD PROTECTION DO YOU WANT; DEFAULT ['WOR']
;    THE PROTECTION WILL BE CHANGED TO ['SYS','OWN','GRO','WOR']
	.ASK OK                                IS THIS CORRECT
.IFF OK .GOTO MOD
PIP 'DISK'[0,0]'GROUP''MEMBER'.DIR/PR/SY:'SYS'/OW:'OWN'/GR:'GRO'/WO:'WOR'
.END:
.ASK MORE DO YOU WANT TO STOP NOW
.IFF MORE .GOTO INPUT
/
