Vi bug: multi-line abbrev w/ ai set

Larry McVoy larry at geowhiz.UUCP
Sat Mar 15 03:59:21 AEST 1986


In article <1727 at ittatc.ATC.ITT.UUCP> yoda at 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 at rsch.wisc.edu                              
Uucp:  {seismo, ihnp4}!uwvax!geowhiz!geophiz!larry      

"Just remember, wherever you go -- there you are."
 	-Buckaroo Banzai



More information about the Comp.unix mailing list