From:	SMTP%"RELAY-INFO-VAX@CRVAX.SRI.COM" 30-AUG-1993 12:22:33.20
To:	EVERHART
CC:	
Subj:	ZRDOS

From: un032371@wvnvms.wvnet.edu
X-Newsgroups: comp.os.vms
Subject: ZRDOS
Message-ID: <1993Aug30.101122.7574@wvnvms.wvnet.edu>
Date: 30 Aug 93 10:11:22 EDT
Organization: West Virginia Network for Educational Telecomputing
Lines: 482
To: Info-VAX@KL.SRI.COM
X-Gateway-Source-Info: USENET

Are you having trouble using Vax/VMS and or tired of typing in brackets
and other difficult symbols with long VMS commands?

I have a program that lets you use most of all the standard dos commands
on vax/vms systems.   It also features a cd command that changes your
prompt like dos does with prompt $p$g.

This program is very easy to install and just as easy to remove.....

If you ever wish you could run dos on the vax I suggest that you give this
program a try.

						Later
						Bryan Baisden
						UN032371@wvnvms.wvnet.edu
						WVU ECE Department
 

$! ------------------ CUT HERE -----------------------
$ v='f$verify(f$trnlnm("SHARE_VERIFY"))'
$!
$! This archive created by VMS_SHARE Version 7.2-007  22-FEB-1990
$!   On 30-AUG-1993 10:08:29.88   By user UN032371 
$!
$! This VMS_SHARE Written by:
$!    Andy Harper, Kings College London UK
$!
$! Acknowledgements to:
$!    James Gray       - Original VMS_SHARE
$!    Michael Bednarek - Original Concept and implementation
$!
$! TO UNPACK THIS SHARE FILE, CONCATENATE ALL PARTS IN ORDER
$! AND EXECUTE AS A COMMAND PROCEDURE  (  @name  )
$!
$! THE FOLLOWING FILE(S) WILL BE CREATED AFTER UNPACKING:
$!       1. ZRINSTALL.COM;1
$!
$set="set"
$set symbol/scope=(nolocal,noglobal)
$f=f$parse("SHARE_TEMP","SYS$SCRATCH:.TMP_"+f$getjpi("","PID"))
$e="write sys$error  ""%UNPACK"", "
$w="write sys$output ""%UNPACK"", "
$ if f$trnlnm("SHARE_LOG") then $ w = "!"
$ ve=f$getsyi("version")
$ if ve-f$extract(0,1,ve) .ges. "4.4" then $ goto START
$ e "-E-OLDVER, Must run at least VMS 4.4"
$ v=f$verify(v)
$ exit 44
$UNPACK: SUBROUTINE ! P1=filename, P2=checksum
$ if f$search(P1) .eqs. "" then $ goto file_absent
$ e "-W-EXISTS, File ''P1' exists. Skipped."
$ delete 'f'*
$ exit
$file_absent:
$ if f$parse(P1) .nes. "" then $ goto dirok
$ dn=f$parse(P1,,,"DIRECTORY")
$ w "-I-CREDIR, Creating directory ''dn'."
$ create/dir 'dn'
$ if $status then $ goto dirok
$ e "-E-CREDIRFAIL, Unable to create ''dn'. File skipped."
$ delete 'f'*
$ exit
$dirok:
$ w "-I-PROCESS, Processing file ''P1'."
$ if .not. f$verify() then $ define/user sys$output nl:
$ EDIT/TPU/NOSEC/NODIS/COM=SYS$INPUT 'f'/OUT='P1'
PROCEDURE Unpacker ON_ERROR ENDON_ERROR;SET(FACILITY_NAME,"UNPACK");SET(
SUCCESS,OFF);SET(INFORMATIONAL,OFF);f:=GET_INFO(COMMAND_LINE,"file_name");b:=
CREATE_BUFFER(f,f);p:=SPAN(" ")@r&LINE_END;POSITION(BEGINNING_OF(b));
LOOP EXITIF SEARCH(p,FORWARD)=0;POSITION(r);ERASE(r);ENDLOOP;POSITION(
BEGINNING_OF(b));g:=0;LOOP EXITIF MARK(NONE)=END_OF(b);x:=ERASE_CHARACTER(1);
IF g=0 THEN IF x="X" THEN MOVE_VERTICAL(1);ENDIF;IF x="V" THEN APPEND_LINE;
MOVE_HORIZONTAL(-CURRENT_OFFSET);MOVE_VERTICAL(1);ENDIF;IF x="+" THEN g:=1;
ERASE_LINE;ENDIF;ELSE IF x="-" THEN IF INDEX(CURRENT_LINE,"+-+-+-+-+-+-+-+")=
1 THEN g:=0;ENDIF;ENDIF;ERASE_LINE;ENDIF;ENDLOOP;t:="0123456789ABCDEF";
POSITION(BEGINNING_OF(b));LOOP r:=SEARCH("`",FORWARD);EXITIF r=0;POSITION(r);
ERASE(r);x1:=INDEX(t,ERASE_CHARACTER(1))-1;x2:=INDEX(t,ERASE_CHARACTER(1))-1;
COPY_TEXT(ASCII(16*x1+x2));ENDLOOP;WRITE_FILE(b,GET_INFO(COMMAND_LINE,
"output_file"));ENDPROCEDURE;Unpacker;QUIT;
$ delete/nolog 'f'*
$ CHECKSUM 'P1'
$ IF CHECKSUM$CHECKSUM .eqs. P2 THEN $ EXIT
$ e "-E-CHKSMFAIL, Checksum of ''P1' failed."
$ ENDSUBROUTINE
$START:
$ create 'f'
X$p="write outf"
X$set Default sys$login
X$create /directory `5B.dos`5D
X$set default `5B.dos`5D
X$open /append outf sys$login:login.com
X$p "$@`5B.dos`5Dzrdos"
X$close outf
X$open/write outf zrdos.com
X$p "$set default sys$login"
X$p "$sdir=f$env(""default"")"
X$p "$name=f$extract(0,f$length(sdir)-1,sdir)"
X$p "$define/nolog dos ","'","name","'",".dos`5D"
X$p "$dir ==""@dos:parse zrdir zark""
X$p "$time ==""show time""
X$p "$attr*ib ==""set prot""
X$P "$cls==""type /page nl:""
X$p "$cd==""@dos:parse zrcd zark""
X$p "$md==""@dos:parse zrmd zark""
X$p "$rd==""@dos:parse zrrd zark""
X$p "$type ==""@dos:parse zrtype zark""
X$p "$move ==""@dos:parse1 zrmove zark1""
X$p "$del*ete ==""@dos:parse zrdel zark""
X$p "$copy ==""@dos:parse1 zrcopy zark""
X$p "$ren*ame ==""@dos:parse1 zrmove zark""
X$p "$e*dit ==""@dos:parse zredit zark""
X$p "$zrhelp==""type dos:zrhelp.txt /p""
X$p "$write sys$output ""Zarker Industries Vms - Dos Emulator Version 1""
X$p "$cd \"
X$close outf
X$open/write outf parse1.com
X$p  "$@dos:parse parse2 ","'","p2"," '","p4 ","'","p1 ","'","p3"
X$close outf
X$open/write outf deinstall.com
X$p "$set default sys$login"
X$p "$set default `5B.dos`5D"
X$p "$@deassign"
X$p "$delete *.*;*"
X$p "$set default sys$login"
X$p "$set prot dos.dir;*"
X$p "$delete dos.dir;*"
X$p "$write sys$output ""Please delete the last line in your login.com to com
Vp"-
X,"lete deinstalling process"
X$p "set prompt=""Zark Off!""
X$ close outf
X$open/write outf deassign.com
X$p "$dir ==""dir""
X$p "$cls ==""cls""
X$p "$time ==""time""
X$p "$attr*ib ==""attrib"
X$p "$cd==""cd""
X$p "$md==""md""
X$p "$rd ==""rd""
X$p "$type ==""type""
X$p "$move ==""move""
X$p "$del*ete ==""delete""
X$p "$copy ==""copy""
X$p "$ren*ame ==""rename""
X$p "$e*dit ==""edit""
X$p "$zrhelp==""zrhelp""
X$close outf
X$open/write outf parse.com
X$p "$dummy=f$env(""default"")"
X$p "$set default sys$login"
X$p "$gdir=f$env(""default"")"
X$p "$set default"," '","dummy"
X$p "$kk=""\""
X$p "$fred1="""" "
X$p "$j=0"
X$p "$fred=p3"
X$p "$if fred.eqs.""."" "
X$p "$then"
X$p "$fred=dummy"
X$p "$endif"
X$p "$if f$extract(0,2,fred).eqs."".."" "
X$p "$then"
X$p "$fred=""`5B.-`5D"" "
X$p "$goto end1"
X$p "$endif"
X$p "$i=f$length(fred)+1"
X$p "$df=i-1"
X$p "$loop:"
X$p "$i=i-1"
X$p "$if f$integr(","'","i) .lt. f$integer(","'","j)"
X$p "$then"
X$p "$if p1.eqs.""ZRMD"".or.p1.eqs.""ZRCD"".or.p2.eqs.""ZARK1"" "
X$p "$then
X$p "$fred=f$extract(0,f$length(dummy)-1,dummy)+"".""+fred+""`5D"" "
X$p "$goto end1"
X$p "$endif"
X$p "$goto end1"
X$p "$endif"
X$p "$if F$extract(i,1,fred).eqs.""`5B"" "
X$p "$then"
X$p "$goto end1"
X$p "$endif"
X$p "$if F$extract(i,1,fred).eqs.kk"
X$p "$then"
X$p "$fred1=f$extract(i+1,df-i,fred)"
X$p "$fred=f$extract(0,i,fred)
X$p "$goto kill"
X$p "$endif"
X$p "$goto loop"
X$p "$kill:"
X$p "$i=-1"
X$p "$j=f$length(fred)"
X$p "$loop3:"
X$p "$i=i+1"
X$p  "$if f$integer(","'","i).gt.f$integer(","'","j)"
X$p  "$then"
X$p  "$goto col"
X$p  "$endif"
X$p  "$if f$extract(i,1,fred).eqs.kk"
X$p  "$then"
X$p  "$fred=f$extract(0,i,fred)+"".""+f$extract(i+1,j-i,fred)"
X$p  "$endif"
X$p  "$if f$extratc(i,1,fred).eqs.""`5B"" "
X$p  "$then"
X$p  "$goto end1"
X$p  "$endif"
X$p  "$goto loop3"
X$p  "$col:"
X$p  "$if fred.eqs."""".or.fred.eqs.""c:"".or.fred.eqs.""C:"" "
X$p  "$then"
X$p  "$fred=gdir"
X$p  "$goto mid1"
X$p  "$endif
X$p  "$if f$extract(0,1,fred).eqs.""."".or.f$extract(0,3,fred).eqs.""c:."".or
V."-
X,"f$extract(0,3,fred).eqs.""C:.""
X$p  "$then
X$p  "$if f$extract(0,1,fred).eqs."".""
X$p  "$then"
X$p  "$fred = f$extract(0,f$length(gdir)-1,gdir)+"".""+f$extract(1,f$length(f
Vr"-
X,"ed)-1,fred)+""`5D"" "
X$p  "$else
X$p  "$fred = f$extract(0,f$length(gdir)-1,gdir)+"".""+f$extract(3,f$length(f
Vr"-
X,"ed)-3,fred)+""`5D"" "
X$p  "$endif"
X$p  "$else
X$p  "$fred = f$extract(0,f$length(dummy)-1,dummy)+"".""+f$extract(0,f$length
V("-
X,"fred),fred)+""`5D"" "
X$p  "$endif"
X$p  "$mid1:"
X$p  "$if fred1.eqs."""" "
X$p  "$then"
X$p  "$fred=fred"
X$p  "$else"
X$p  "$sled=p1"
X$p  "$if sled.eqs.""zrmd"" "
X$p  "$then"
X$p  "$goto skip"
X$p  "$endif"
X$p  "$set default ","'","fred"
X$p  "$ned=f$search("" ","'","'","fred1","'",".dir"")"
X$p  "$set default ","'","dummy"
X$p  "$if ned.eqs."""" "
X$p  "$then"
X$p  "$fred1=fred1"
X$p  "$else"
X$p  "$skip:"
X$p  "$fred=f$extract(0,f$length(fred)-1,fred)+"".""+fred1+""`5D"" "
X$p  "$fred1="""" "
X$p  "$endif"
X$p  "$fred=fred+fred1"
X$p  "$endif"
X$p  "$end1:"
X$p  "$pp2=fred"
X$p  "$pp3=p4"
X$p  "$pp4=p5"
X$p  "$pp5=p6"
X$p  "$goto ","'","p1"
X$p  "$zrmd:"
X$p "$create /dir 'pp2"
X$p  "$goto end2"
X$p "$zrrd:"
X$p "$set prot 'pp2.dir;*"
X$p "$delete 'pp2.dir;*"
X$p  "$goto end2"
X$p  "$zrcd:"
X$p "$kk="".""
X$p "$fred=pp2"
X$p "$lf=f$length(fred)"
X$p "$fredz=fred"
X$p "$dummy=f$env(""default"")"
X$p "$set default sys$login"
X$p "$gdir=f$env(""default"")"
X$p  "$set default"," '","dummy"
X$p "$set default ","'","fred"
X$p "$dir=""c:""
X$p "$sdir=f$env(""default"")"
X$p "$i=-1"
X$p "$j=f$length(sdir)"
X$p "$loop:"
X$p "$i=i+1"
X$p "$if f$integr(","'","i) .gt. f$integer(","'","j)"
X$p "$then $goto out"
X$p "$endif"
X$p "$if F$extract(i,1,sdir).eqs.kk"
X$p "$then $goto out"
X$p "$endif"
X$p "$goto loop"
X$p "$out:"
X$p "$if F$extract(0,i,sdir).eqs.F$extract(0,i,gdir)"
X$p "$then $name=""'","'","dir","'",".","'","'","f$extract(i+1,F$length(sdir)
V-"-
X,"2-i,sdir)","'",">""
X$p "$else"
X$p "$sdir=f$env(""default"")"
X$p "$name=""'","'","f$extract(0,F$length(sdir)-1,sdir)","'",">""
X$p "$endif"
X$p "$i=0"
X$p "$jj=""`5B""
X$p "$loop2:"
X$p "$ff=f$extract(i,1,name)"
X$p "$if ff.eqs.kk .or. ff.eqs.jj"
X$p "$then"
X$p "$name=""'","'","f$extract(0,i,name)","'","\","'","'","f$extract(i+1,F$le
Vn"-
X,"gth(name),name)","'""
X$p "$endif"
X$p "$if f$integer(F$length(name)).eq.f$integer(i)"
X$p "$then $goto prompttime"
X$p "$endif"
X$p "$i=i+1"
X$p "$goto loop2"
X$p "$prompttime:"
X$p "$set prompt =","'","name"
X$p  "$goto end2"
X$p  "$parse2:"
X$p  "$@dos:parse ","'","pp3 "," '","pp2"," '","pp4 ","'","pp2"
X$p  "$goto end2"
X$p  "$zrdir:"
X$p  "$on error then goto redir"
X$p "$dir ==""dir""
X$p "$dir  'pp2 'pp3 "
X$p "$show quota"
X$p "$redir:"
X$p "$dir ==""@dos:parse zrdir zark""
X$p  "$goto end2"
X$p  "$zrdel:"
X$p "$del*ete ==""del""
X$p "$on error then goto redel"
X$p  "$del ","'","pp2 ","'","pp3"
X$p "$redel:"
X$p "$del*ete ==""@dos:parse zrdel zark""
X$p  "$goto end2"
X$p  "$zrmove:"
X$p  "$on error then goto reren"
X$p  "$ren*ame==""rename""
X$p  "$rename ","'","pp2 ","'","pp3", " '","pp4"
X$p  "$reren:"
X$p "$ren*ame ==""@dos:parse1 zrmove zark""
X$p  "$goto end2"
X$p  "$zrtype:"
X$p  "$type==""type""
X$p  "$on error then goto retyp"
X$p  "$type ","'","pp2 ","'","pp3"
X$p  "$retyp:"
X$p "$type ==""@dos:parse zrtype zark""
X$p  "$goto end2"
X$p  "$zrcopy:"
X$p "$copy ==""copy""
X$p "$on error then goto recop"
X$p  "$copy ","'","pp2 ","'","pp3"
X$p  "$recop:"
X$p  "$copy ==""@dos:parse1 zrcopy zark""
X$p  "$goto end2"
X$p  "$zredit:"
X$p  "$on error then goto reed"
X$p "$e*dit ==""edit""
X$p "$define/nolog sys$input sys$command"
X$p "$edit ","'","pp2 ","'","pp3"
X$p "$reed:"
X$p "$e*dit ==""@dos:parse zredit zark""
X$p  "$end2:"
X$close outf
X$open/write outf ZRhelp.txt
X$p "The following commands are available in ZRdos Version 1"
X$p ""
X$p "       ZRdos Features Prompt $P$G and NO Zarking Brackets`5B.`5D"
X$p ""
X$p "           dir    --  Shows files and free space"
X$p "           del    --  Deletes a file"
X$p "           type   --  Types a file"
X$p "           copy   --  Copies a file"
X$p "           edit   --  Edits a file"
X$p "           rename --  Renames a file"
X$p "           attrib --  Sets protection"
X$p "           md     --  Creates a directory "
X$p "           cd     --  Changes to a directory"
X$p "           rd     --  Deletes a directory"
X$p "           move   --  Moves a file"
X$p "           time   --  Shows the current time"
X$p "           ZRhelp --  Displays this help menu"
X$p " "
X$p "  "
X$p "-dir `7Bdirectory`7D"
X$p "      This command displays the contents of the current directory"
X$p "      or the directory specified and the amount of space available"
X$p "      in the account logged into.  Very similar to a standard dos dir."
X$p ""
X$p "-md  `5Bdirectory`5D"
X$p "      This command creates directories.  It works very similarly to "
X$p "      standard dos md."
X$p "      "
X$p "      eg.   $md c:\tmp  "
X$p "      "
X$p "      This would create a directory called tmp seen by DCL as `5B.tmp`5D
V"
X$p ""
X$p "-cd `5Bdirectory`5D"
X$p "      CD performs operations similar to dos cd."
X$p "       "
X$p "      eg.  $cd tmp  or  $cd c:\tmp  or  $cd \tmp"
X$p ""
X$p "      This will change the directory to `5B.tmp`5D and change the prompt
V"
X$p ""
X$p "       cd \  sets the directory to the login directory."
X$p "       cd ..  steps back a directory."
X$p ""
X$p "-rd `5Bdirectory`5D"
X$p "     rd functions just as dos rd."
X$p ""
X$p "     eg.  Directory tmp is empty and feels like being decimated."
X$p "          The command $rd tmp deletes the directory."
X$p ""
X$p "-move `7Bdirectory`7D`5Bfilename`5D `5Bdirectory`5D"
X$p "     Moves a file from the current directory to another directory."
X$p ""
X$p "     eg.  $move c:\filename c:\tmp"
X$p ""
X$p "-copy `7Bdirectory`7D`5Bfilename`5D `7Bdirectory`7D`5Bfilename`5D"
X$p "     Copies a file from the current directory to another directory."
X$p ""
X$p "     eg.  $copy c:\filename c:\tmp
X$p ""
X$p "-del `7Bdirectory`7D`5Bfilename`5D"
X$p "     Deletes a file"
X$p ""
X$p "-type `7Bdirectory`7D`5Bfilename`5D"
X$p "     Types a file"
X$p ""
X$p "-edit `7Bdirectory`7D`5Bfilename`5D"
X$p "     Edits a file"
X$p ""
X$p "-attrib `7Bdirectory`7D`5Bfilename`5D"
X$p "     Performs a VMS set protection operation"
X$p ""
X$p "-rename  `7Bdirectory`7D`5Bfilename`5D `7Bdirectory`7D`5Bfilename`5D"
X$p "     Renames a file"
X$p ""
X$p ""
X$p "-prompt $p$g"
X$p "             The prompt is set to $p$g automatically on a cd command."
X$p "             The login directory is assumed to be the root directory"
X$p "             and changing to other directories above the root directory"
X$p "             will result in their name being treated as a different driv
Ve."
X$p ""
X$p ""
X$p "   To Deinstall ZRdos type @dos:deinstall."
X$p "   To temporarily turn ZRdos of type @dos:deassign."
X$close outf
X$p="write sys$output"
X$p "ZRdos has been installed"
X$p ""
X$p "A line has been added to your login.com file to setup ZRdos."
X$p ""
X$p "Typing ZRhelp will give you help and the features of ZRdos."
X$p ""
X$p ""
X$p "License Agreement"
X$p ""
X$p "    If this product is to be used for an extended period of time"
X$p "    then it should be registered.  Registration will entitle the"
X$p "    user to all future upgrades and user help support."
X$p "    Registration can be accomplished by mailing ten dollars along with"
X$p "    your address and/or internet address to"
X$p ""
X$p "            Zarker Industries"
X$p "            c/o Bryan Baisden"
X$p "            Po. Box 82"
X$p "            Romney WV 26757"
X$p ""
X$p "Any questions can be refered to Internet address UN032371@wvnvms.wvnet.e
Vdu"
X$p ""
X$@ZRdos
$ CALL UNPACK ZRINSTALL.COM;1 1846717979
$ v=f$verify(v)
$ EXIT

