On Jan 16, 2012, at 1:53 PM, Tim Chase wrote:

> On 01/16/12 12:04, Eric Weir wrote:
> 
>> Thanks, Tim--and to everyone else who responded. My guess is
>> it was hitting u while in visual mode. I have not advanced to
>> the stage of using commands beginning with a g or a v. I'll
>> check out the ones you suggest.
> 
> well, the "v" ones are ones done in visual mode, which it sounds like you're 
> already using.  Pressing u/U/~/? in visual mode transform the selection 
> accordingly (lowercasing, uppercasing, swap-casing, and ROT13ing).  The other 
> "g" variants perform the same transformations over the text covered by 
> <motion>

I misspoke. Yes, I do use v and V--frequently! What puzzles me in this case is 
that the changes took place over an extended block of text. As I write I can 
see how that would have happened. Most of what was changed was in folds. If I 
selected the folds I would've selected everything in the fold.

>> "diff" is one of those things I hear about here that I haven't
>> gotten around to checking out, yet. Likewise with "grep". I've
>> assumed they're more relevant to programmers, which I
>> definitely am not. But as you suggest with "diff," I'm pretty
>> certain that even programmers' tools can be put to good use in
>> plain old writing--if you've gone to the trouble of finding
>> out about them.
> 
> "diff"ing just means comparing two files.  For code, the standard diff occurs 
> line-wise, and Vim has great support for this.  To try it out, take a file, 
> edit it and save it to a different name.  Then start vim with
> 
>  vimdiff orig_file.txt modified_file.txt
> 
> (or "vim -d orig_file.txt modified_file.txt", or issue ":diffthis" in each of 
> two existing windows/buffers you want to compare).  You might want to walk 
> through
> 
>  :help diff.txt

I took a look at that after reading the responses to my post. I'll be checking 
it out further, i.e., experimenting with actually using it. I can imagine it 
coming in useful sometime.

> and try out what you see in there with two mostly-the-same junk files you 
> have floating around.  The most helpful things to know are the dp/dg (or 
> ":diffput" and ":diffget" commands) for moving changes between the two files.
> 
> As discussed recently in a parallel thread, if you have flowing text where 
> paragraphs are reflowed inserting linebreaks (rather than your paragraphs 
> being all on one line), it's not quite as useful.  For that, you might 
> investigate "wdiff" to compare the files.

Hmm. Haven't encountered the concept of "flowing" text previously. I believe my 
paragraphs have two linebreaks between them.

Thanks,
------------------------------------------------------------------------------------------
Eric Weir
Decatur, GA
[email protected]

"What is man without the beasts? If all the beasts were gone, 
men would die from a great loneliness of spirit." 

- Chief Seattle






-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to