yoda@ittatc.ATC.ITT.UUCP (Todd C. Williams [Jedi Knight]) (03/12/86)
I want to have an abbreviation that will print out the following 5 lines: main(argc,argv) int argc; char *argv[]; { } I want to put this is my .exrc file. I have already set autoindent in this file. The problem is that, with autoindent set, multiline abbreviations are tabbed in by autoindent, with (apparently) no way to stop this. I tried the obvious ^D's, but to no avail, even when lnext quoted. Can anyone help? EXAMPLES that do NOT work: THIS (in .exrc): set autoindent abbreviate aaaaa main(argc,argv)^M^Iint argc;^Mchar *argv[];^M^D{^M} PRODUCES: main(argc,argv) int argc; char *argv[]; { } adding additional ^D's, quoted or not, does not work. We are running 4.1bsd on a VAX-11/780. -Todd Williams -- +------------------------------------------------------------------------------+ | Todd C. Williams | "Summer blonds | | ITT Defense Communications | revealing tan lines, | | Nutley, NJ | I'll make more moves than | | {decvax, et al.}!ittatc!dcdvaxb!tcw | ALLIED VAN LINES!" | | I love to receive e-mail from anyone!| --from: "I wanna be a lifeguard" | | | by BLOTTO | +------------------------------------------------------------------------------+
larry@geowhiz.UUCP (Larry McVoy) (03/14/86)
In article <1727@ittatc.ATC.ITT.UUCP> yoda@ittatc.ATC.ITT.UUCP (Todd C. Williams [Jedi Knight]) writes: >EXAMPLES that do NOT work: > >THIS (in .exrc): > >set autoindent >abbreviate aaaaa main(argc,argv)^M^Iint argc;^Mchar *argv[];^M^D{^M} Umm... this is too simple to work, but how about: abbreviate foo :set noai Imain(argc,argv)^M^Iint argc;^Mchar *argv[];^M^D{^M}:set ai Which, escapes out of insert, sets no ai, does it, escapes, sets ai back. I know, a kludge. -- Larry McVoy ----------- Arpa: mcvoy@rsch.wisc.edu Uucp: {seismo, ihnp4}!uwvax!geowhiz!geophiz!larry "Just remember, wherever you go -- there you are." -Buckaroo Banzai