Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83 (MC840302); site ark.UUCP Path: utzoo!linus!philabs!cmcl2!seismo!mcvax!vu44!botter!ark!maartenj From: maartenj@ark.UUCP (Maarten Jan Huisjes) Newsgroups: net.bugs.4bsd Subject: Re: The yank command in vi. Message-ID: <622@ark.UUCP> Date: Mon, 6-Jan-86 10:25:16 EST Article-I.D.: ark.622 Posted: Mon Jan 6 10:25:16 1986 Date-Received: Tue, 7-Jan-86 07:10:27 EST References: <355@weitek.UUCP> <1670@ihuxl.UUCP> Reply-To: maartenj@ark.UUCP (Huisjes Maarten Jan) Organization: VU Informatica, Amsterdam Lines: 23 Keywords: vi Y map >> ... I contend it would be a more useful and more consistent >> implementation of Y to yank to end of line. > > Have you ever tried the string "y$" ? After all since the vi > command syntax seems to be that > should work! And whadayaknow it does! I bet "d$" and "c$" work > too but I think "D" is a lot easier. However, "c$" comes in handy > now and then. You too can makeup new vi commands everyday or maybe > only every other day! Actually, maybe they're not new except to you. > Show them to your friends! Post'em to the net! After all, someone > might be looking for that particular "new" command. :-) If your version of vi supports the "map" command you could even do this : :map Y y$ Actually you can just about map everything to anything as long as the mapped string is a one character or if the string does not start with a alpha character. It is a very useful command, for instance you can map whole C-constructions to one or two keys !! -- Maarten Jan Huisjes. (maartenj@ark.UUCP) {seismo|decvax|philabs}!mcvax!vu44!ark!maartenj