On Fri, Jun 16, 2023 at 6:28 PM 'Susan McElheny' via vim_use <vim_use@googlegroups.com> wrote:
I have used VI on Unix for over 30 years and now have to use it in Windows where it works much differently. If I open gVim 9.0 in a GUI session, how do I open another file without having to go to the top with my mouse and select File, Open? At the command level I can just :vi "filename", but I've been having issues working with VI at the command level - maybe be because it didn't like that I made the window larger as people have just mentioned.Hopefully a simple question for you experts!Susan McElheny
Senior Analyst, Data Operations
Apart from the fact that you ought to have started a new thread and not jumped onto any passing thread with an unrelated question:
To open a 2nd (or 3rd, ..., nth) file in a new window in a running Vim or gvim on any OS, just do
:new filename.ext
or
:split filename.ext
replacing filename.ext by the desired filename (with path if necessary).
If, instead, you want to _replace_ the file currently being edited by another one in the same window, then do
:e filename.ext
If the file has modifications, Vim will refuse to wipe it out (unless 'autowriteall' is on, which is not the default): in that case you should either save the file first, or use :e! instead of :e to forget all changes.
See
:h :new
:h :split_f
:h :edit
and also accessorily
:h 'awa'
:h ++opt
:h +cmd
:h +cmd
Best regards,
Tony.
--
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
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/CAJkCKXs24xzyH%2BKxdRGHKFc4AuGtVhOODi2gO1fNwqUfKJg08g%40mail.gmail.com.
No comments:
Post a Comment