home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Simtel MSDOS 1992 June
/
SIMTEL_0692.cdr
/
msdos
/
keyboard
/
cedwars2.arc
/
DAVECED.NOT
< prev
next >
Wrap
Text File
|
1988-07-25
|
10KB
|
232 lines
07-25-88
I have worked out some fairly nifty (if I do say so myself) CED macros which
I think a lot of people might find useful. Since sitting down and poring over
a file isn't my idea of fun either, I've made up this annotated list. The file
I actually use (this week) is in this arc as DAVECED.CFG
Dave Williams
******************************************************************************
rem **Globals** ;first, REM the hell out of everything.
;REMs don't take up any space in memory
;and are handy for remembering what's going on
syn @ E:\ram\xeq ;I used XEQ.COM, which allows you to store a
;bunch of little .COM files in one large one
;to save disk space (remember, each little
;30 byte file takes up 2k to 8k of disk!)
syn ed dp12 C:\wp\pcw^ed.exe %1 ;DP12 is a path enhancer, allows PC-Write
;to find its help file in C:\wp\pcw. PC-Write
;(ed.exe) itself is in the path in the RAMdisk.
;%1 is a replaceable parameter for the filename
;just like DOS batch language
rem **PATHING**
syn normpath path=E:\;C:\bat;C:\ut;C:\dos ;restores my default PATH if I
;change it or some dweeb program
;rapes it
rem **PROMPT**
syn myprompt prompt $p$_$q$q$g ;resets my usual prompt, which puts the
;path on top and commands on the bottom,
;since I hate looking 6 inches over for
;what I'm typing in if 9 dirs down....
syn prompt1 prompt $a╔═ $p$_$a╚══$g ;betcha didn't know you could put high
;ASCII chars intothje prompt, didya?
syn promptr prompt $e[7m$p$_$q$q$g
syn prompt2 prompt $e[1m$e[s$e[1;1H$e[37;40m$e[K $d $t$h$h$h $v $e[uCommand:$e[0m
syn prompt3 prompt $e[1m$e[s$e[25;1H$e[37;40m$e[K $a Current Logged Volume and Directory: $p$g$h $e[u$q$q$g$e[0m
rem **DIRECTORY STUFF**
syn a A: ;lets me jump to A: with a<enter>, 2 keystrokes
rem syn b B:
syn b D:^cd\book ;don't have a B: drive now, so jump to most
;used subdirectory
syn c C:
syn 4 D: ;d is better used as dir, so it's drive 4
syn e E:
syn cpa copy A:*.* ;saves 14 keystrokes!
syn d dir/p ;good ol' DIR, and /P to break it up
syn da dir/p A:
syn sd ^@ sdir ;^@ - @ is our macro for "XEQ". CED wants a
;leading command before it will let a macro
;be the first command of another macro, so
;the chain character "^" does it. Saves 3
;bytes of RAM per XEQ instruction
syn sda ^@ sdir A:
syn la label A:
rem syn dx ^@ direx
syn de dir/p E:^pause^xeq/l > E:xeqlist^@ list E:xeqlist
;a fancy macro. Gives a directory of stuff in
;the RAMdisk (utilities, usually), then XEQ/L
;to see what's in XEQ (also in RAMdisk) piped
;to a file called xeqlist, then LIST.COM lets
;you see what's in xeqlist
syn c2pc C:\ut\copy^copyiipc
rem syn ddwg dir \cad\*.pd1
rem syn dwks dir/w \calc\wks\*.wk?
syn up cd.. ;very handy for going up in subdirectories
syn next ^@ next
syn down ^@ down
syn dn ^@ dirnotes
syn ck chkdsk %1 ;you need the %1 to take the optional params
syn more ^@ more
syn delbak del *.bak ;zap TPascal .BAK files
rem **XEQ**
syn dsort ^@ dirsort N^d ;uses Norton's DIRSORT from XEQ, then brings
;up the directory
syn see ^@ list ;brings LIST.COM from XEQ
syn fdate ^@ fdate
syn cal ^@ cal
rem syn qt ^@ qt
rem syn sweep ^@ sweep
syn rdir ^@ rdir
syn red ^@ red
syn where ^@ where
syn sz ^@ size
syn fr ^@ free
syn vt ^@ vtree
syn vtg ^@ vtree > E:vtree.pic^@ list E:vtree.pic ;another fancy macro, feeds
;VTREE into a file, then
;look at it with list
syn vtl ^@ list E:vtree.pic ;lets you look again without waiting for VTREE
rem ** GOING SOMEWHERE? **
syn !1 pushdir^rem Current Directory Saved ;good old pushdir and popdir
syn !2 ^@ popdir^rem Returned to Saved Directory ;and their macros
rem syn !bat cd\bat ;I use ! to indicate these are directory-
;jumping macros. Saves a lot of typing.
syn !dn D:^cd\dnld
syn !up cd\comm\upld
syn !dmp cd\comm\dmp
syn !boot cd\dos\boot
syn !ram cd\dos\boot\ram
syn !df cd\wp\df
rem syn !wr cd\wp\wr
syn !ltr cd\wp\ltr
syn !asm cd\pro\asm
syn !tp cd\pro\tp
syn !lib cd\work\lib
rem syn !diag cd\ut\diag
syn !trm cd\pro\tp\trm
syn !pas cd\pro\tp\pas
syn !asm cd\pro\asm\asrc
syn !joe cd\pro\tp\joe
rem syn !cal cd\pro\tp\calc
rem **CALLING EXECUTABLE FILES**
syn basic \pro\bas\basica %1
syn #jiv C:\wp\jive < %1 > %2 ;these are for operating filters,
syn #val C:\wp\valspeak < %1 > %2 ;take care of all redirection, etc.
syn aform C:\wp\aform < %1 > %2 -l -b -w
syn qm C:\comm\qmodem/L %1^cls
syn #mac C:\fun\macpaint -ok -invert
;I'm especially proud of these macros for running Turbo Pascal 3x. They take
;you through all the drivel menus and feed your filename in at the right
;place. PC Mag's KEYFAKE was the only one that would work correctly for
;the 64k segment macro
syn tpa dp12 C:\pro\tp^keyfake "YOCQC%1" 13^C:\pro\tp\turbo
rem default: takes all availible RAM
syn tp dp12 C:\pro\tp^keyfake "YOCA 1000" 13 "QC%1" 13^C:\pro\tp\turbo
rem 64k segment
syn edarc ^ed C:\wp\df\archive
syn edlib ^ed C:\work\lib\softcat
syn edli2 ^ed C:\work\lib\softcat2
syn edli3 ^ed C:\work\lib\softcat3
syn format33 C:\dos\33\format A: %1 %2 %3
syn x2 \pro\exe2bin %1 %2
rem **EDITING THE SYSTEM FILES**
syn edced ^ed \dos\boot\ced.cfg ;this macro brings up PC-Write to edit the
;CED.CFG file.
syn edcfg attr -H-R \config.sys^ed \config.sys^attr +H+R \config.sys
;this one uses PCMag's ATTR.COM to unhide
;CONFIG.SYS, bring up the editor, and then
;hide it when I'm done
syn edboot ^ed \dos\boot\boot.bat
;my AUTOEXEC merely loads BOOT into the
;RAMdisk and transfers control to it. BOOT
;is the actual autoexec. AUTOEXEC is hidden
;and read-only, to foil those moron
;INSTALL.COM programs that zap your stuff.
rem **ARCHIVING STUFF**
syn arc pkarc ax ;prompts for comment for archive
syn arcx pkxarc
syn look pkarc vm ;toggles MORE?
rem **PCALLS**
pcall look
pcall see
pcall msc ;these are all PCALLed. If I edit a file, each
pcall asm ;time I type ed<enter> CED will automatically
pcall tpa ;bring that file back up for editing. Same for
pcall tp ;the assembler or compilers. Speeds programming
pcall ed ;enormously
rem **CED STATUS STUFF**
chainch ^ ;I use the default chain character
ignorech ~ ;this is my IGNORE character
syn newced ced clear syn^ced clear pcall^ced -FC:\dos\boot\ced.cfg
;this is one of my favorite macros. Once I've
;edited the config file with EDCED, I can make
;CED clear the SYN and PCALL buffers and load
;the newly edited cfg file. Works great!
syn seeced ^@ list E:ced.cfg
;I load ced.cfg into the RAMdisk and use
;LIST.COM to view it if I forget a command.
;^T scrolls by 'way too fast to read
rem **USERSYN**
rem UserSyns work fine for Infocom games
;I usually define syns on the fly. Old
;Infocom games worked fine with CED, new ones
;are doing no-nos and bypass DOS (and therefore
;CED). LIST.COM is also CED compatible
******************************************************************************
I use a couple of lengthy batch files to run MASM and Microsoft C, since I
keep the files out of the path (I have to use lengthy pathnames) and I clean
up the .OBJ and .BIN files, etc. I could have done it in CED, but it wasn't
worth it to suck up RAM for something I didn't use often.
Remember CED will take all DOS batch commands, replaceable parameters, etc.
Be leery of defining a CED macro as an already existing DOS command name, CED
syn dir or whatever can throw you into an endless loop.
PC Magazine's KEYFAKE.COM is extremely useful with CED. It's a TSR, but it is
small and well behaved. With KEYFAKE and CED you can make software to really
nifty tricks.