Xref: utzoo comp.editors:576 alt.flame:5296 Path: utzoo!censor!becker!ziebmef!ncrcan!hcr!stacey From: stacey@hcr.UUCP (Stacey Campbell) Newsgroups: comp.editors,alt.flame Subject: Re: Vi bashing Keywords: holy mackerel Message-ID: <24@hcr.UUCP> Date: 23 Mar 89 01:50:02 GMT References: <587@alice.marlow.uucp> <4048@ttidca.TTI.COM> <960@myrias.UUCP> Reply-To: stacey@hcrvax.UUCP (Stacey Campbell) Organization: HCR Corporation, Toronto Lines: 51 You gotta see this to believe it, truly a case of the moronic leading the blind. In article <960@myrias.UUCP> dbf@myrias.UUCP writes: >In article <4048@ttidca.TTI.COM> kevin@ttidcb.tti.com (Kevin Carothers) writes: >>I am continuously amazed at the lack of knowledge about Vi some of the >>people who post to this newsgroup display! Ditto. >>NO, you DO NOT have to count lines! [to delete a block of text] >>1. Mark the beginning and end of your block of text >> Lets say the beginning is register "a", and the end is "b". >>2. Enter the following command: >> :'a,'bw !wc -l >> +---- This space is very important. +---- This command is totally twisted. >>If you don't like Vi, fine. Just don't post untrue junk about it. > >Thanks for posting an ingenious and elegant solution. >With my amazing lack of knowledge of vi, it would have taken me >hours of pulling together information scattered among many >pages of UNIX documentation on vi, ex, and wc to come up with >this nifty get-around. [...] This little exchange just totally freaks me out. Of all the ways to delete text in vi I have never seen this solution, can anyone think of a more bizarre way to do this? For reality try... :'a,'bd or if the cursor is at the end of the range for deletion... :'a,.d for orthogonal functionality... d[any mark] where [any mark] is: 'a - to mark 'a $ - to end of line /[search string] - to char before start of [search string] G - to end of file etc... -- Stacey Campbell, HCR Corporation, {lsuc,utzoo,utcsri}!hcr!stacey