On 07/01/09 21:13, Gene Kwiecinski wrote:
>> I was wondering if anybody has a best practice to open multiple files
>> that each reside on different machines over the network. I plan to use
>> VIM because that is my primary tool for reading files.
>
>> I can manually open all of them one by one and have multiple vim
>> windows open, but I am hoping there is a better way.
>
> You *can* specify more than one file at a time in a single 'vim'
> instance, and/or hit another file with 'argadd' and add a new file to
> the filelist.  From there, you can keep just one window/instance and use
> ":n" to get to the next file, then next, next, next, etc., then ":rew"
> to rewind back to the first file, and so on.  Think ":N" is to switch to
> the previous file.  For sure, "^^" (ctl-^) toggles between the current
> file and the last one you were editing.
>
> Each time it switches to another file, it'll refresh.
>
> Me personally, I don't like window-splits, so I rarely if ever use that
> other'n diffing files, so if that's what you were looking for, someone
> else will have to fill you in on details.

Alternately, you can tell Vim to open the current window full-height and 
squash all other windows to a status line and nothing else, in the 
fashion of a Rolodex cardholder: slips before the current one have their 
names visible at top, slips after the current one have their names 
visible at bottom, any one of them can be accessed immediately by 
clicking its name (its status line) or by <number> Ctrl-W w --or you can 
go from one to the next with Ctrl-W w or back to the previous one with 
Ctrl-W W

Here's how:

        :set noequalalways winminheight=0 winheight=9999 helpheight=9999

For easy "walking" I also have the following mappings:
        :map    <F11>           <C-W>w
        :map    <S-F11>         <C-W>W

The above are in my vimrc. In addition, to open several files in 
split-windows, just use (for instance)

        gvim -o3 file1.txt file2.txt file3.txt

see
        :help -o

Best regards,
Tony.
-- 
It was one of those perfect summer days -- the sun was shining, a
breeze was blowing, the birds were singing, and the lawn mower was
broken ...
                -- James Dent

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to