Path: utzoo!attcan!uunet!bloom-beacon!usc!apple!agate!ucbvax!hplabs!hpl-opus!steinbac From: steinbac@hpl-opus.HP.COM (Gunter Steinbach) Newsgroups: comp.editors Subject: Re: Register Commands in Vi Message-ID: <62420005@hpl-opus.HP.COM> Date: 21 Sep 89 16:30:32 GMT References: <518@dcdwest.UUCP> Organization: HP Labs, High Speed Electronics Dept., Palo Alto, CA Lines: 19 'Nother try, this time with control characters expanded - sorry!!! This line in your .exrc should work: map \ lb"xdEPo0^V^D:n! ^["xp"xdd@x ^^execute buffer x ^^^^remove the new line into buffer x ^^^add the stored word to the new line ^^^^^^^^^^^^make new line with ":n! ", no indentation ^^^^^^^put the word under the cursor into buffer x Usage: put the cursor anywhere on the file name, hit \. You better have previous changes saved, or they'll be lost. Add :w of the macro for automatic writing. Good luck! Guenter Steinbach | hplabs!gunter_steinbach | gunter_steinbach@hplabs.hp.com