www.LinuxHowtos.org

6. Editing Multiple Files


Editing multiple files in vi is possible in two different ways:



  1. invoke vi with multiple files on the command line

  2. use command :e from within vi


Once the files are loaded, movement from one file to another can be
accomplished using following commands:


 
:n - next file
:e# - previous file
Ctrl-^ - last edited file, keep cursor on last edited line

 
/* The article above and any accompanying files are freely
* distributable, but please leave this notice and the text intact.
* Home for this document: http://www.infobound.com/vi.html
* Copyright (C) 1994, 1999 Tony Thomas
* Contact author through email:tony@infobound.com
* Last revision Feb 23, 1999
* UNIX is a trademark of X/Open
*/

rate this article:
current rating: average rating: 1.3 (27 votes) (1=very good 6=terrible)
Your rating:
Very good (1) Good (2) ok (3) average (4) bad (5) terrible (6)

back