home *** CD-ROM | disk | FTP | other *** search
Text File | 1993-04-23 | 51.1 KB | 1,260 lines |
- Newsgroups: comp.sources.misc
- From: mool@oce.nl (Bram Moolenaar)
- Subject: v37i022: vim - Vi IMitation editor v1.27, Part22/24
- Message-ID: <1993Apr25.013900.23433@sparky.imd.sterling.com>
- X-Md4-Signature: c67e6af7711a2f25d375d4af82fe3cf4
- Date: Sun, 25 Apr 1993 01:39:00 GMT
- Approved: kent@sparky.imd.sterling.com
-
- Submitted-by: mool@oce.nl (Bram Moolenaar)
- Posting-number: Volume 37, Issue 22
- Archive-name: vim/part22
- Environment: UNIX, AMIGA, MS-DOS
-
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then unpack
- # it by saving it into a file and typing "sh file". To overwrite existing
- # files, type "sh file -c". You can also feed this as standard input via
- # unshar, or by typing "sh <file", e.g.. If this archive is complete, you
- # will see the following message at the end:
- # "End of archive 22 (of 23)."
- # Contents: vim/doc/reference.doc1
- # Wrapped by mool@oce-rd2 on Mon Apr 19 15:50:14 1993
- PATH=/bin:/usr/bin:/usr/ucb ; export PATH
- if test -f 'vim/doc/reference.doc1' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'vim/doc/reference.doc1'\"
- else
- echo shar: Extracting \"'vim/doc/reference.doc1'\" \(48721 characters\)
- sed "s/^X//" >'vim/doc/reference.doc1' <<'END_OF_FILE'
- X
- X
- X
- X VIM reference manual
- X
- X By Bram Moolenaar
- X
- X version 1.27
- X
- X
- X 1. Introduction
- X 2. Notation
- X 3. Starting VIM
- X 4. Modes
- X 5. Editing files
- X 6. Cursor motions
- X 7. Scrolling
- X 8. Tags
- X 9. Inserting text
- X10. Deleting text
- X11. Changing text
- X12. Copying and moving text
- X13. Quoting
- X14. Various commands
- X15. Repeating commands
- X16. Undo and redo
- X17. Key mapping
- X18. Recovery after a crash
- X19. Options
- X20. Terminal information
- X21. Differences from Vi and Ex
- X22. Credits
- X
- X
- X 1. Introduction
- X
- XVIM stands for Vi Imitation. VIM is a text editor which includes almost all
- Xthe commands from the Unix program "Vi". It is very useful for editing
- Xprograms and other ASCII text. All commands are given with the keyboard.
- XThere is no mouse support and there are no menus. This gives the advantage
- Xthat you can keep your fingers on the keyboard and your eyes on the screen.
- X
- XThroughout this manual the differences between Vi and Vim are mentioned in
- Xcurly braces. Read the file "difference.doc" for a summary of the
- Xdifferences.
- X
- XThis manual refers to VIM on the Commodore Amiga computer. On other
- Xcomputers and on terminals there may be small differences. For MSDOS this
- Xis documented in msdos.doc. For UNIX this is in unix.doc.
- X
- XThis manual is a reference for all the VIM commands and options. A basic
- Xknowledge of "Vi" is assumed. A summary of this manual can be found in the
- Xfile vim.hlp. It can be accessed from within VIM with the <HELP> key (in
- XMSDOS <F1>) and with the command ":help". The 'helpfile' option can be
- Xset to the name of the help file, so you can put it in any place you like.
- X
- X
- X 2. Notation
- X
- X[] Characters in square brackets are optional.
- X
- X[cnt] An optional number that may precede the command to multiply
- X or iterate the command. If no number is given a count of one
- X is used, unless otherwise noted. Note that in this manual
- X the [cnt] is not mentioned in the description of the
- X command, but only in the explanation. This was done to make
- X the commands more easy to lookup. If the "sc" option is on,
- X the (partially) entered count is shown at the bottom of the
- X window. You can use <DEL> to erase the last digit.
- X
- X["x] An optional named register designation where text can be
- X stored. The x is a single character between <a> and <z> or
- X <A> and <Z> and in some cases (with the put command) between
- X <0> and <9> or <.>. The uppercase and lower case letter
- X designate the same register, but the lower case letter is
- X used to overwrite the previous register contents, while the
- X uppercase letter is used to append to the previous register
- X contents. Without the ""x" the deleted text is put into the
- X unnamed register.
- X
- X{} Curly braces denote parts of the command which must appear,
- X but can take a number of different values. The differences
- X between VIM and Vi are also given in curly braces (this will
- X be clear from the context).
- X
- X{motion} A command that moves the cursor. They are listed in chapter
- X 6. This is used after an "operator" command to move over the
- X text that is to be operated upon. If the motion includes a
- X count and the operator also had a count, the two counts are
- X multiplied. For example: "2d3w" deletes six words.
- X
- X{quote} A piece of text that is started with the 'q' or 'Q' command
- X and ended by the cursor position. This is used before an
- X "operator" to highlight the text that is to be operated
- X upon. See the chapter on quoting.
- X
- X<character> A special character from the table below or a single ASCII
- X character.
- X
- X<char1-char2> A single character from the range <char1> to <char2>. For
- X example: <a-z> is a lower case letter. Multiple ranges may be
- X concatenated. For example: <a-zA-Z0-9> is any alphanumeric
- X character.
- X
- XCTRL-<char> <char> typed as a control character, that is, typing <char>
- X while holding the CTRL key down. The case of <char> does not
- X matter, thus CTRL-A and CTRL-a are equivalent.
- X
- X
- Xnotation meaning equivalent hex value
- X-----------------------------------------------------------------------
- X<NUL> zero CTRL_@ 0x00 (or 0x9e)
- X<BELL> bell CTRL-G 0x07
- X<BS> backspace CTRL-H 0x08
- X<TAB> tab CTRL-I 0x09
- X<LF> linefeed CTRL-J 0x0a
- X<NL> newline CTRL-J 0x0a (same as linefeed)
- X<FF> formfeed CTRL-L 0x0c
- X<CR> carriage return CTRL-M 0x0d
- X<ESC> escape CTRL-[ 0x1b
- X<SPACE> space 0x20
- X<DEL> delete 0x7f
- X<C_UP> cursor-up 0x80
- X<C_DOWN> cursor-down 0x81
- X<C_LEFT> cursor-left 0x82
- X<C_RIGHT> cursor-right 0x83
- X<SC_UP> shift-cursor-up 0x84
- X<SC_DOWN> shift-cursor-down 0x85
- X<SC_LEFT> shift-cursor-left 0x86
- X<SC_RIGHT> shift-cursor-right 0x87
- X<F1> - <F10> function keys 1 to 10 0x88 - 0x91
- X<SF1> - <SF10> shift-function keys 1 to 10 0x92 - 0x9b
- X<HELP> help key 0x9c
- X<UNDO> undo key 0x9d
- X-----------------------------------------------------------------------
- X
- X
- X 3. Starting VIM
- X
- X3.1 Command line
- X
- XMost often VIM is started to edit a single file with the command
- X
- X vim file
- X
- XMore generally VIM is started with:
- X
- X vim [options] [filelist]
- X
- XIf the filelist is missing, the editor will start with an empty buffer.
- XOtherwise exactly one out of the following six may be used to choose one or
- Xmore files to be edited.
- X
- Xfile .. A list of file names. The first one will be the current file
- X and read into the buffer. The cursor will be positioned on
- X the first line of the buffer.
- X
- X+[num] file .. Same as the above, but the cursor will be positioned on line
- X "num". If "num" is missing, the cursor will be positioned on
- X the last line.
- X
- X+/{pat} file .. Same as the above, but the cursor will be positioned on the
- X first line containing "pat" in the current file (see the
- X section "pattern searches" for the available search
- X patterns).
- X
- X+{command} file ..
- X-c {command} file ..
- X Same as the above, but "command" will be executed after the
- X file has been read. "command" is interpreted as an Ex
- X command. If the "command" contains spaces it must be
- X enclosed in double quotes (this depends on the shell that is
- X used). Example: Vim "+set si" main.c
- X
- X-t {tag} A tag. "tag" is looked up in the tags file, the associated
- X file becomes the current file and the associated command is
- X executed. Mostly this is used for C programs. In that case
- X "tag" should be a function name. The effect is that the file
- X containing that function becomes the current file and the
- X cursor is positioned on the start of the function (see the
- X section "tag searches").
- X
- X-e QuickFix mode. The error file "AztecC.Err" is read and the
- X first error is displayed. See the section "using the
- X QuickFix option".
- X
- XThe options, if present, must precede the filelist. The options may be given
- Xin any order.
- X
- X-r Recovery mode. The autoscript file is read to recover a
- X crashed editing session. It has almost the same effect as
- X "-s file.vim". See the chapter "Recovery after a crash".
- X
- X-v View mode. The 'readonly' option will be set and no
- X autoscript file will be written (see -n below). You can
- X still edit the buffer, but will be prevented from
- X accidentally overwriting a file. If you forgot that you are
- X in view mode and did make some changes, you can overwrite
- X a file by adding an exclamation mark to the Ex command, as in
- X ":w!". The 'readonly' option can be reset with ":set noro"
- X (see the options chapter). It is suggested to make an alias:
- X "alias view vim -v".
- X
- X-n No autoscript file will be written. Recovery after a crash
- X will be impossible. Handy if you want to edit a file on a
- X very slow medium (e.g. floppy). Can also be done with ":set
- X uc=0". You can switch it on again by setting the 'uc' option
- X to some value, e.g. ":set uc=100" (only do this if the
- X buffer was not changed yet).
- X
- X-T {terminal} Set the terminal type to "terminal". This influences the
- X codes that Vim will send to your terminal. This is normally
- X not needed, because Vim will be able to find out what type
- X of terminal you are using (See chapter 20).
- X
- X-d {device} The "device" is opened to be used for editing. Normally you
- X would use this to set the window position and size:
- X "-d con:x/y/width/height", e.g. "-d con:30/10/600/150". But
- X you can also use it to start editing on another device, e.g.
- X AUX:. This only works on the Amiga.
- X
- X-s {scriptin} The script file "scriptin" is read. The characters in the
- X file are interpreted as if you had typed them. The same can
- X be done with the command ":source! {scriptin}". If the end
- X of the file is reached before the editor exits, further
- X characters are read from the keyboard. See also the section
- X "complex repeats".
- X
- X-w {scriptout} All the characters that you type are recorded in the file
- X "scriptout", until you exit VIM. This is useful if you want
- X to create a script file to be used with "vim -s" or
- X ":source!". See also the section "complex repeats".
- X
- XExample for using a script file to change a name in several files:
- X Create a file "subs.vi" containing substitute commands and a :wq
- X command:
- X
- X :%s/Jones/Smith/g
- X :%s/Allen/Peter/g
- X :wq
- X
- X Execute VIM on all files you want to change:
- X
- X foreach i ( *.let ) vim -s subs.vi $i
- X
- X
- X3.2 Workbench (Amiga only)
- X
- XVim can be started from the workbench by clicking on its icon twice. It will
- Xthen start with an empty buffer.
- X
- XVim can be started to edit one or more files by using a "Project" icon. The
- X"Default Tool" of the icon must be the full pathname of the Vim executable.
- XThe name of the ".info" file must be the same as the name of the text file.
- XBy clicking on this icon twice, Vim will be started with the filename as
- Xcurrent filename, which will be read into the buffer (if it exists). You can
- Xedit multiple files by pressing the shift key while clicking on icons, and
- Xclicking twice on the last one. The "Default Tool" for all these icons must
- Xbe the same.
- X
- XIt is not possible to give arguments to Vim, other than filenames, from the
- Xworkbench.
- X
- X
- X3.3 Vim window
- X
- XVIM will run in the CLI window where it was started. If VIM was started with
- Xthe "run" or "runback" command, or if VIM was started from the workbench, it
- Xwill open a window of its own.
- X
- XTechnical detail:
- X To open the new window a little trick is used. As soon as VIM
- X recognizes that it does not run in a normal CLI window, it will
- X create a script file in t:. This script file contains the same
- X command as how VIM was started, and an "endcli" command. This script
- X file is then executed with a "newcli" command (the "c:run" and
- X "c:newcli" commands are required for this to work). The script file
- X will hang around until reboot, or until you delete it. This method
- X is required to get the ":sh" and ":!" commands to work correctly.
- X But when Vim was started with the -e option (quickfix mode), this
- X method is not used. The reason for this is that when a compiler
- X starts Vim with the -e option it will wait for a return code. With
- X the script trick the compiler cannot get the return code. As a
- X consequence the ":sh" and ":!" commands are not available when the
- X -e option is used.
- X
- XVIM will automatically recognize the window size and react to window
- Xresizing. Under Amiga DOS 1.3 it is advised to use the fastfonts program
- X"FF" to speed up display redrawing.
- X
- X
- X3.4 Initialization
- X
- XWhen VIM starts running it does initializations in this order:
- X
- X1. Four places are searched for initializations. The first that exists is
- X used, the others are ignored.
- X 1. The environment variable VIMINIT
- X 2. The file "s:.vimrc" (for Unix: "$HOME/.vimrc")
- X 3. The environment variable EXINIT
- X 4. The file "s:.exrc" (for Unix: "$HOME/.exrc")
- X
- X2. The current directory is searched for two files. The first that exists
- X is used, the other is ignored.
- X 1. The file ".vimrc"
- X 2. The file ".exrc"
- X
- X If an environment variable is used, it is executed as a single Ex
- X command line. Multiple commands must be separated with '|'. If a file is
- X used, each line is executed as an Ex command line.
- X
- X3. The environment variable SHELL, if it exists, is used to set the
- X 'shell' option.
- X
- X4. The environment variable TERM, if it exists, is used to set the 'term'
- X option.
- X
- XThe first can be used to set your default settings and mappings for all edit
- Xsessions. The second one for sessions in a certain directory. See the
- Xsection "Saving settings" for how to create a file with commands to recreate
- Xthe current settings.
- X
- XIf the VIMINIT environment variable or ".vimrc" exist the EXINIT and ".exrc"
- Xare skipped. This can be used to initialize Vim without interfering with
- Xanother version of Vi.
- X
- XOn the Amiga two types of environment variables exist. The ones set with the
- XDOS 1.3 (or later) setenv command are recognized. See the AmigaDos 1.3
- Xmanual. The environment variables set with the old Manx Set command (before
- Xversion 5.0) are not recognized.
- X
- XWhile reading the ".vimrc" and the ".exrc" file some commands are disabled
- Xfor security reasons. Otherwise it would be possible to create a .exrc that
- Xcontains nasty commands, which another user may automatically execute when
- Xhe starts Vim it that directory. The disabled commands are the ones that
- Xstart a shell and the ones that write to a file. The ":map" commands are
- Xechoed, so you can see which keys are being mapped. (On unix systems this
- Xonly happens if you are not the owner of the ".vimrc" or ".exrc" file.)
- X
- X
- X3.5 Suspending
- X
- XCTRL-Z Suspend the editor. Same as ":stop!".
- X
- X:st[op][!] Suspend the editor. If the "!" is not given,
- X the buffer was changed, autowrite is set and
- X a filename is known, the buffer will be
- X written.
- X
- XOn BSD-UNIX systems it is possible to suspend Vim with CTRL-Z. This is only
- Xpossible in command mode (see next chapter). Vim will restart if you make it
- Xthe foreground job again. On other systems CTRL-Z will start a new shell.
- XThis is the same as the ":sh" command. Vim will restart if you exit from the
- Xshell.
- X
- X
- X 4. Modes
- X
- X4.1 Introduction
- X
- XVIM has four basic modes:
- X
- Xcommand mode In command mode you can enter all the editor
- X commands. If you start the editor you are in this
- X mode (unless you have set the 'insertmode' option,
- X see below).
- X
- Xinsert mode In insert mode the text you type is inserted into the
- X buffer. If the 'showmode' option is set (which is
- X default), the string "-- INSERT --" is shown at the
- X bottom of the window.
- X
- Xreplace mode Replace mode is a special case of insert mode. You
- X can do the same things as in insert mode, but for
- X each character you enter (except some special
- X characters) one character of the existing text is
- X deleted. If the 'showmode' option is set (which is
- X default), the string "-- REPLACE --" is shown at the
- X bottom of the window.
- X
- Xcommand line mode In command line mode you can enter one line of text
- X at the bottom of the window. This is for the Ex
- X commands, the pattern search commands and the filter
- X command.
- X
- XMore explanation on the insert, replace and command line mode is further on
- Xin this chapter.
- X
- X
- X4.2 Switching from mode to mode
- X
- XIf for any reason you do not know in which mode you are, you can always get
- Xback to command mode by typing <ESC> twice. You will know you are back in
- Xcommand mode when you see the screen flash or hear the bell after you type
- X<ESC>.
- X
- X- go from command mode to insert mode by giving one of the commands
- X "iIaAoOcCsS".
- X- go from command mode to replace mode with the "R" command (not the "r"
- X command!).
- X- go from command mode to command line mode with the one of the commands
- X ":/?!".
- X
- X- go from insert or replace mode to command mode with <ESC> (twice in some
- X rare cases).
- X- go from command line mode to command mode with <CR> (which causes the
- X entered command to be executed), by deleting the complete line (e.g. with
- X CTRL-U) and giving a final <BS>, or by hitting <ESC> twice. In the last
- X case the first <ESC> will also be used to start filename completion, but
- X you can ignore that.
- X
- XIf the 'insertmode' option is set, editing a file will start in insert mode.
- X
- X
- X4.3 Insert and replace mode
- X
- XIn insert and replace mode the following characters have a special meaning,
- Xother characters are inserted directly. To insert one of these special
- Xcharacters into the buffer, precede it with CTRL-V. To insert a <NUL>
- Xcharacter use CTRL-V CTRL-J (the <NUL> is actually stored as a <LF> in
- Xmemory, but replaced with a <NUL> when written to a file). To insert a
- XCTRL-C use "CTRL-V003".
- X
- Xchar action
- X-----------------------------------------------------------------------
- XCTRL-@ Insert previously inserted text and stop insert. {Vi: only
- X when typed as first char, only upto 128 chars}
- XCTRL-A Insert previously inserted text. {not in Vi}
- XCTRL-B <0-9a-z>
- X Insert the contents of a numbered or named register (see
- X chapter on copying and moving text). 'B' stands for buffer,
- X which is called register in this document. {not in Vi}
- XCTRL-D Delete one shiftwidth of indent at the start of the current
- X line. See also 'shiftround' option. {Vi: only after
- X auto-indent; also accepts preceding <^> and <0>}
- XCTRL-E Insert the character which is below the cursor. {not in Vi}
- XCTRL-H <BS> Delete the character before the cursor (see below). {Vi:
- X does not delete autoindents}
- XCTRL-J <LF> Begin new line.
- XCTRL-K {char1} {char2}
- X Enter digraph (see below). {not in Vi}
- XCTRL-M <CR> Begin new line.
- XCTRL-O See below. {not in Vi}
- XCTRL-R Insert the character which is above the cursor. {not in Vi}
- XCTRL-T Insert one shiftwidth of indent at the start of the current
- X line. See also 'shiftround' option. {Vi: only when in
- X autoindent}
- XCTRL-U Delete all entered characters in the current line (see
- X below).
- XCTRL-V Insert next non-digit literally. Up to three digits form the
- X decimal value of a single byte. All this without mapping.
- X {Vi: no decimal byte entry}
- XCTRL-W Delete the word before the cursor (see below). See the
- X section "word motions" for the definition of a word.
- XCTRL-[ <ESC> End insert or replace mode, back to command mode.
- X<DEL> Same as CTRL-H <BS>
- X-----------------------------------------------------------------------
- X
- XThe effect of the <BS>, <DEL>, CTRL-W and CTRL-U depends on the 'backspace'
- Xoption:
- X
- Xbackspace action
- X option
- X 0 delete stops in column 1 and start position of insert
- X 1 delete stops at start position of insert
- X 2 delete always, CTRL-W and CTRL-U stop once at start position of
- X insert
- X
- XIf the 'backspace' option is non-zero and the cursor is in column 1 when one
- Xof the three keys is used, the current line is joined with the previous
- Xline. This effectively deletes the newline in front of the cursor. {Vi: does
- Xnot cross lines, does not delete past start position of insert}
- X
- XWith CTRL-V followed by one, two or three digits you can enter the decimal
- Xvalue of a byte, except 10. Normally CTRL-V is followed by three digits. The
- Xformed byte is inserted as soon as you type the third digit. If you type
- Xonly one or two digits and then a non-digit, the decimal value of those one
- Xor two digits form the byte. After that the non-digit is dealt with in the
- Xnormal way.
- X
- XIf you enter a value of 10, it will be interpreted as a 0. The 10 is a <LF>,
- Xwhich is used internally to represent the NUL character. When writing the
- Xbuffer to a file the <LF> character is translated into <NUL>. The <LF>
- Xcharacter is written at the end of each line. Thus if you want to insert a
- X<LF> character in a file you will have to make a line break.
- X
- X
- Xspecial keys
- X
- XThe following keys are special. They stop the current insert, do something
- Xand then restart insertion. This means you can do something without getting
- Xout of insert mode. This is very handy if you prefer to use the insert mode
- Xall the time, just like editors that don't have a separate command mode. You
- Xmay also want to set the 'backspace' option to 2 and set the 'insertmode'
- Xoption. You can map often used commands to function keys by preceding them
- Xwith a CTRL-O.
- X
- XThe changes (inserted or deleted characters) before and after these keys can
- Xbe undone separately. Only the last change can be redone and always behaves
- Xlike an 'i' command.
- X
- Xchar action
- X-----------------------------------------------------------------------
- X<C_UP> cursor one line up
- X<C_DOWN> cursor one line down
- X<C_LEFT> cursor one character left
- X<C_RIGHT> cursor one character right
- X<SC_UP> move window one page up
- X<SC_DOWN> move window one page down
- X<SC_LEFT> cursor one word back (like 'b' command)
- X<SC_RIGHT> cursor one word forward (like 'w' command)
- XCTRL-O execute one command and return to insert mode
- X-----------------------------------------------------------------------
- X
- XThe CTRL-O command has one side effect: If the cursor was beyond the end of
- Xthe line it will be put on the last character in the line.
- X
- X
- X'textwidth' option
- X
- XThe 'textwidth' option can be used to automatically break a line before it
- Xis getting too long. Set the 'textwidth' option to the maximum line length.
- XIf you then type more characters (not being spaces or tabs), the last word
- Xwill be put on a new line (unless it is the only word on the line). {Vi has
- Xthe 'wrapmargin' option, but it does not do what you want}.
- X
- XIf you want to format a block of text you can use the 'V' operator. Type 'V'
- Xand a movement command to move the cursor to the end of the block. In many
- Xcases the command "V}" will do what you want (format until the next empty
- Xline). Or you can use quoting: hit 'q', move to the end of the block and hit
- X'V'.
- X
- X
- X'expandtab' option
- X
- XIf the 'expandtab' option is set, spaces will be used to fill the amount of
- Xwhitespace of the tab. If you want to enter a real <TAB> use CTRL-V. The
- X'expandtab' option is normally off.
- X
- X
- Xdigraphs
- X
- X:dig[raph] show currently defined digraphs. {not in Vi}
- X
- X:dig[raph] {char1}{char2} {number} ...
- X Add digraph {char1}{char2} to the list. {number} is
- X the decimal representation of the entered character.
- X
- XDigraphs are used to enter characters that normally cannot be entered by
- Xan ordinary keyboard. These are mostly accented characters which have the
- Xeighth bit set. The digraphs are more easy to remember than the decimal
- Xnumber that can be entered with CTRL-V (see above).
- X
- XVim must have been compiled with the 'digraphs' option enabled. If not, the
- X":digraph" command will display an error message.
- X
- XThere are two methods to enter digraphs:
- X CTRL-K {char1} {char2} or
- X {char1} <BS> {char2}
- XThe first is always available. The second only when the 'digraph' option is
- Xset.
- X
- XOnce you have entered the digraph the character is treated like a normal
- Xcharacter, taking up only one character in the file and on the screen.
- XExample:
- X <|> <BS> <|> will enter the double <|> character (166)
- X <a> <BS> <^> will enter an 'a' with a hat (226)
- X CTRL-K <-> <-> will enter a minus sign (173)
- X
- XThe default digraphs are listed in the file digraph.doc. They are meant for
- Xthe Amiga character set, which is some international standard. With another
- Xcharacter set they may be illogical.
- X
- XIf you accidently typed an <a> that should be an <e>, you will type <a> <BS>
- X<e>. But that is a digraph, so you will not get wat you want. To avoid this,
- Xuse <DEL> instead of <BS>.
- X
- X
- Xreplace mode
- X
- XIn replace mode one character in the line is deleted for every character you
- Xtype. If there are no characters to delete (at the end of the line), the
- Xtyped character is appended (as in insert mode). Thus the number of
- Xcharacters in a line stays the same until you get to the end of the line.
- X
- XBe careful with <TAB> characters. If you type a normal printing character in
- Xits place, the number of characters is still the same, but the number of
- Xcolumns will become smaller.
- X
- XThe 'repdel' option influences what happens if you delete characters in
- Xreplace mode (with <BS>, <DEL>, CTRL-W or CTRL-U). If 'repdel' is on (the
- Xdefault) the characters are really deleted. For example: If you made a
- Xtyping error and hit <BS> to correct it, the number of characters in the
- Xline will be one less. This is sometimes illogical, because replace mode was
- Xmade to keep the number of characters the same. If you reset 'repdel', the
- Xcharacters are not deleted but only the cursor is moved, so you can then
- Xcorrect your typing error.
- X
- X
- X4.4 Command line mode
- X
- XCommand line mode is used to enter Ex commands, search patterns and <!>
- Xcommands.
- X
- X
- X4.4.1 Command line editing
- X
- XNormal characters are inserted in front of the cursor position. You can move
- Xaround in the command line with the left and right cursor keys. {Vi: can
- Xonly alter the last character in the line}
- X
- XThe command lines that you enter are remembered in a history table. You can
- Xrecall them with the up and down cursor keys. Use the 'history' option to
- Xset the number of lines that are remembered (default 20).
- X
- XCTRL-V Insert next non-digit literally. Up to three digits form the
- X decimal value of a single byte. All this without mapping.
- X This works the same way as in insert mode (see above). {Vi:
- X type the CTRL-V twice to get one}
- X<C_LEFT> cursor left
- X<C_RIGHT> cursor right
- X<SC_LEFT> cursor one word left
- X<SC_RIGHT> cursor one word right
- X
- X<BS> delete the character in front of the cursor
- X<DEL> delete the character under the cursor (at end of line:
- X character in front of the cursor)
- XCTRL-U remove all characters
- X
- X<C_UP> recall older command line from history
- X<C_DOWN> recall more recent command line from history
- X
- XCTRL-D list filenames that match the pattern in front of the cursor
- X<ESC> do filename completion on the pattern in front of the cursor
- XCTRL-N after <ESC> with multiple matches: go to next match;
- X otherwise: recall more recent command line from history
- XCTRL-P after <ESC> with multiple matches: go to previous match;
- X otherwise: recall older command line from history
- X
- XIn the pattern for CTRL-D and <ESC> standard Amiga wildcards are accepted,
- Xplus the <*> and <?> characters.
- X
- XFor filename completion you can use the 'suffixes' option to set a priority
- Xbetween files with almost the same name. If there are multiple matches,
- Xthose files with a file extension that is in the 'suffixes' option are
- Xignored. The default is ".bak.o.h.info.vim", which means that files with the
- Xextensions ".bak", ".o", ".h", ".info" and ".vim" are sometimes ignored. It
- Xis impossible to ignore suffixes with two dots. Examples:
- X
- Xpattern: files: match:
- Xtest* test.c test.h test.o test.c
- Xtest* test.h test.o test.h and test.o
- Xtest* test.i test.h test.c test.i and test.c
- X
- X
- X4.4.2 Ex command lines
- X
- XThe Ex commands have a few specialities:
- X
- X<"> or <#> at the start of a line causes the whole line to be ignored. <">
- Xafter a command causes the rest of the line to be ignored. This can be used
- Xto add comments.
- X
- X<|> can be used to separate commands, so you can give multiple commands in
- Xone line. The commands ":global", ":vglobal" and ":!" see the <|> as their
- Xargument, and can therefore not be followed by another command.
- X
- XWhen the character <%> or <#> is used where a filename is expected, they are
- Xexpanded to the current and alternate filename (see the chapter "editing
- Xfiles").
- X
- XEmbedded and trailing spaces in filenames are allowed if one filename is
- Xexpected as argument (":next {file..}" uses the space to separate filenames).
- X
- XWhen you want to use the special characters <"> or <|> in a command, or want
- Xto use <%> or <#> in a filename, precede them with a backslash. The backslash
- Xis not required in a range and in the ":substitute" command.
- X
- X
- X4.4.3 Ex command line ranges
- X
- XSome Ex commands accept a line range in front of them. This is noted as
- X[range]. It consists of one or more line specifiers, separated with ',' or
- X';'. When separated with ';' the cursor position will be set to that line
- Xbefore interpreting the next line specifier. The default line specifier for
- Xmost commands is the cursor position, but the commands ":write" and
- X":global" have the whole file (1,$) as default. If more line specifiers are
- Xgiven than required for the command, the first one(s) will be ignored.
- X
- XLine numbers may be specified with:
- X {number} an absolute line number
- X . the current line
- X $ the last line in the file
- X % equal to 1,$ (the entire file)
- X 't position of mark t (lower case)
- X /{pattern}[/] the next line where {pattern} matches
- X ?{pattern}[?] the previous line where {pattern} matches
- X
- XEach may be followed (several times) by '+' or '-' and an optional number.
- XThis number is added or subtracted from the preceding line number. If the
- Xnumber is omitted, 1 is used.
- X
- XThe '/' and '?' may be preceded with another address. The search starts from
- Xthere. The '/' and '?' after {pattern} are required to separate the pattern
- Xfrom anything that follows.
- X
- XThe {number} must be between 0 and the number of lines in the file. A 0 is
- Xinterpreted as a 1, except with the commands tag, pop and read.
- X
- XExamples:
- X .+3 three lines below the cursor
- X /that/+1 the line below the next line containing "that"
- X .,$ from current line until end of file
- X 0/that the first line that containing "that"
- X
- XSome commands allow for a count after the command. This count is used as the
- Xnumber of lines to be used, starting with the line given in the last line
- Xspecifier (the default is the cursor line).
- X
- XExamples:
- X :s/x/X/g 5 substitute <x> by <X> in the current line and four
- X following lines
- X :23d 4 delete lines 23, 24, 25 and 26
- X
- X
- X4.5 The window contents
- X
- XIn command and insert/replace mode the screen window will show the current
- Xcontents of the buffer: What You See Is What You Get. {Vi: when changing
- Xtext a <$> is placed on the last changed character; The window is not always
- Xupdated on slow terminals} Lines longer than the window width will wrap. The
- Xbottom lines in the window may start with one of these two characters:
- X
- X<@> The next line is too long to fit in the window.
- X<~> Below the last line in the buffer.
- X
- XIf the bottom line is completely filled with <@>, the line that is at the
- Xtop of the window is too long to fit in the window. If the cursor is on this
- Xline you can't see what you are doing, because this part of the line is not
- Xshown. However, the part of the line before the <@>s can be edited normally.
- X{Vi: gives an "internal error" on lines that do not fit in the window}
- X
- XAll normal ASCII characters are displayed directly on the screen. The <TAB>
- Xis replaced by the number of spaces that it represents. Other non-printing
- Xcharacters are replaced by "^<char>", where <char> is the non-printing
- Xcharacter with 64 added. Thus character 7 (bell) will be shown as "^G".
- XCharacters between 127 and 160 are replaced by "~<char>", where <char> is
- Xthe character with 64 subtracted. These characters occupy more than one
- Xposition on the screen. The cursor can only be positioned on the first one.
- X
- XIf you set the 'number' option, all lines will be preceded with their
- Xnumber.
- X
- XIf you set the 'list' option, <TAB> characters will not be shown as several
- Xspaces, but as "^I". A <$> will be placed at the end of the line, so you can
- Xfind trailing blanks.
- X
- XIn command line mode only the command line itself is shown correctly. The
- Xdisplay of the buffer contents is updated as soon as you go back to command
- Xmode.
- X
- XSome commands hand over the window to external commands (e.g. ":shell" and
- X"="). After these commands are finished the window may be clobbered with
- Xoutput from the external command, so it needs to be redrawn. This is also
- Xthe case if something is displayed on the status line that is longer than
- Xthe width of the window. If you are expected to have a look at the screen
- Xbefore it is redrawn, you get this message:
- X
- X Press RETURN or enter command to continue
- X
- XAfter you type a key the screen will be redrawn and Vim continues. If you
- Xtype <CR>, <SP> or <NL> nothing else happens. If you type any other key, it
- Xwill be interpreted as (the start of) a new command. {Vi: only <:> commands
- Xare interpreted}
- X
- XThe last line of the window is used for status and other messages. The
- Xstatus messages will only be used if an option is on:
- X
- Xstatus message option default
- Xcurrent mode 'showmode' on
- Xcommand characters 'showcmd' on
- Xcursor position 'ruler' off
- X
- XThe current mode is "-- INSERT --" or "-- REPLACE --". The command
- Xcharacters are those that you typed but were not used yet. {Vi: does not show the characters you
- Xtyped or the cursor position}
- X
- XIf you have a slow terminal you can switch off the status messages to speed
- Xup editing:
- X :set nosc noru nosm
- X
- XIf there is an error, an error message will be shown for at least one second
- X(in reverse video). {Vi: error messages may be overwritten with other
- Xmessages before you have a chance to read them}
- X
- XSome commands show how many lines were affected. Above which threshold this
- Xhappens can be controlled with the 'report' option (default 2).
- X
- XOn the Amiga VIM will run in a CLI window. The name VIM and the full name of
- Xthe current filename will be shown in the title bar. When the window is
- Xresized, VIM will automatically redraw the window. You may make the window as
- Xsmall as you like, but if it gets too small not a single line will fit in it.
- XMake it at least 40 characters wide to be able to read most messages on the
- Xlast line.
- X
- X
- X 5. Editing files
- X
- X5.1 Introduction
- X
- XEditing a file with VIM means:
- X
- X1. reading the file into the internal buffer
- X2. changing the buffer with editor commands
- X3. writing the buffer into a file
- X
- XAs long as you don't write the buffer, the original file remains unchanged.
- XIf you start editing a file (read a file into the buffer), the file name is
- Xremembered as the "current filename".
- X
- XIf there already was a current filename, then that one becomes the alternate
- Xfile name. Up to 20 older alternate filenames are remembered in a list. When
- Xyou enter a filename, for editing (e.g. with ":e filename") or writing (e.g.
- Xwith (:w filename"), the filenames shift one down in this list. You can use
- Xthis list to remember which files you edited and to quickly switch from one
- Xfile to another with the CTRL-^ command (e.g. to copy text). {Vi: only one
- Xalternate filename}
- X
- XIn Ex commands (the ones that start with a colon) you can refer to the
- Xcurrent filename with <%> and refer to the alternate filename with <#> or
- X"#0". The older alternate filenames are "#1", "#2", ..., "#20".
- X
- XCTRL-G or
- X:f[ile] Prints the current filename and the cursor position.
- X
- X:f[ile] {name} Sets the current filename to {name}.
- X
- X:files Lists the alternate filenames.
- X
- XWhen writing the buffer, the default is to use the current filename. Thus
- Xwhen you give the "ZZ" or ":wq" command, the original file will be
- Xoverwritten. If you do not want this, the buffer can be written into another
- Xfile by giving a filename argument to the ":write" command. For example:
- X
- X vim testfile
- X [change the buffer with editor commands]
- X :w newfile
- X :q
- X
- XThis will create a file "newfile", that is a modified copy of "testfile".
- XThe file "testfile" will remain unchanged. Anyway, if the 'backup' option is
- Xset, VIM renames the original file before it will be overwritten. You can
- Xuse this file if you discover that you need the original file. The name of
- Xthe backup file is the same as the original file with ".bak" appended. Any
- X'.' is replaced by '_' on MSDOS machines, when Vim has detected that an
- XMSDOS-like filesystem is being used (e.g. messydos or crossdos) and when the
- X'shortname' option is set.
- X
- XTechnical: On the Amiga you can use 30 characters for a file name. But on an
- X MSDOS-compatible filesystem only 8 plus 3 characters are
- X available. Vim tries to detect the type of filesystem when it is
- X creating the .vim file. If an MSDOS-like filesystem is suspected,
- X a flag is set that has the same effect as setting the 'shortname'
- X option. This flag will be reset as soon as you start editing a
- X new file. The flag will be used when making the filename for the
- X ".vim" and ".bak" files for the current file. But when you are
- X editing a file in a normal filesystem and write to an MSDOS-like
- X filesystem the flag will not have been set. In that case the
- X creation of the ".bak" file may fail and you will get an error
- X message. Use the 'shortname' option.
- X
- XVIM remembers whether you have changed the buffer. You are protected from
- Xloosing the changes you made. If you try to quit without writing, or want to
- Xstart editing another file, this will be refused. In order to overrule this
- Xprotection add a <!> to the command. The changes will then be lost. For
- Xexample: ":q" will not work if the buffer was changed, but ":q!" will. To see
- Xwhether the buffer was changed use the "CTRL-G" command. The message includes
- Xthe string "[Modified]" if the buffer has been changed.
- X
- X
- X5.2 Editing a file
- X
- X:e [+pat] Edit the current file, unless changes have been made.
- X
- X:e! [+pat] Edit the current file always. Discard any changes to
- X the buffer.
- X
- X:e[dit] [+pat] {file} Edit {file}, unless changes have been made.
- X
- X:e[dit]! [+pat] {file} Edit {file} always. Discard any changes to the
- X buffer.
- X
- X:ex [+pat] [file] Same as :edit.
- X
- X:vi[sual] [+pat] [file] Same as :edit. {Vi: go from Ex to visual mode}
- X
- XCTRL-^ Edit [cnt]th (default 0) alternate file (equivalent
- X to ":e #[cnt]"). If the 'autowrite' option is set
- X and the buffer was changed, write it. This is a
- X quick way to toggle between two (or more) files.
- X
- X:cd Print the current directory name. {Vi: go to home
- X directory}
- X
- X:cd {path} Change the current directory to {path}.
- X
- X:chd[ir] [path] Same as :cd.
- X
- XThese commands are used to start editing a single file. This means that the
- Xfile is read into the buffer and the current filename is set. You may use the
- X":cd" command to get to another directory, so you will not have to type that
- Xdirectory name in front of the filenames.
- X
- XYou can use the ":e!" command if you messed up the buffer and want to start
- Xall over again. The ":e" command is only useful if you have changed the
- Xcurrent filename.
- X
- XThe [+pat] can be used to position the cursor in the newly opened file:
- X + Start at the last line.
- X +{num} Start at line {num}.
- X +/{pat} Start at first line containing {pat}. {pat} must not
- X contain any spaces.
- X +{command} Execute {command} after opening the new file.
- X {command} is an Ex command. It must not contain
- X spaces.
- X
- X
- X5.3 The file list
- X
- XIf you give more than one filename when starting VIM, this list is remembered
- Xas the file list. You can use this list with the following commands:
- X
- X:ar[gs] Print the file list, with the current file in "[]".
- X
- X:[count]n[ext] Edit [count] next file, unless changes have been
- X made and the 'autowrite' option is off {Vi: no
- X count}.
- X
- X:[count]n[ext]! Edit [count] next file, discard any changes to the
- X buffer {Vi: no count}.
- X
- X:n[ext] [+pat] {filelist}
- X Define {filelist} as the new list of files and edit
- X the first one, unless changes have been made and the
- X 'autowrite' option is off.
- X
- X:n[ext]! [+pat] {filelist}
- X Define {filelist} as the new list of files and edit
- X the first one. Discard any changes to the buffer.
- X
- X:[count]N[ext] Edit [count] previous file in file list, unless
- X changes have been made and the 'autowrite' option is
- X off {Vi: no count}.
- X
- X:[count]N[ext]! Edit [count] previous file in file list. Discard any
- X changes to the buffer {Vi: no count}.
- X
- X:[count]pre[vious] Same as :Next {Vi: no count}.
- X
- X:rew[ind] Start editing the first file in the file list, unless
- X changes have been made and the 'autowrite' option is
- X off.
- X
- X:rew[ind]! Start editing the first file in the file list.
- X Discard any changes to the buffer.
- X
- X:[count]wn[ext] Write current file and start editing the [count]
- X next file. {not in Vi}
- X
- X:[count]wn[ext] {file} Write current file to {file} and start editing the
- X [count] next file, unless {file} already exists and
- X the 'writeany' option is off.
- X {not in Vi}
- X
- X:[count]wn[ext]! {file} Write current file to {file} and start editing the
- X [count] next file. {not in Vi}
- X
- XThe [count] in the commands above defaults to one.
- X
- XThe wildcards in the file list are expanded and the filenames are sorted.
- XThus you can use the command "vim *.c" to edit all the C files. From within
- XVIM the command ":n *.c" does the same.
- X
- XYou are protected from leaving VIM if you are not editing the last file in
- Xthe file list. This prevents you from forgetting that you were editing one
- Xout of several files. You can exit anyway, and save any changes, with the
- X":wq!" command. To loose any changes use the ":q!" command.
- X
- X
- X5.4 Writing and quitting
- X
- X:[range]w[rite][!] Write the specified lines to the current file.
- X
- X:[range]w[rite] {file} Write the specified lines to {file}, unless it
- X already exists and the 'writeany' option is off.
- X
- X:[range]w[rite]! {file} Write the specified lines to {file}. Overwrite an
- X existing file.
- X
- X:[range]w[rite][!] >> Append the specified lines to the current file.
- X
- X:[range]w[rite][!] >> {file}
- X Append the specified lines to {file}.
- X
- X:[range]w[rite] !{cmd} Execute {cmd} with [range] lines as standard input
- X (note the space in front of the <!>).
- X
- XThe default [range] for the ":w" command is the whole buffer (1,$).
- X
- X
- X:q[uit] Quit, unless changes have been made or not editing
- X the last file in the file list.
- X
- X:q[uit]! Quit always, without writing.
- X
- X:cq Quit always, without writing, and return an error
- X code. Used for Manx's QuickFix option (see 5.5).
- X
- X:wq Write the current file. Exit if not editing the
- X last file in the file list.
- X
- X:wq! Write the current file and exit.
- X
- X:wq {file} Write to {file}. Exit if not editing the last
- X file in the file list.
- X
- X:wq! {file} Write to {file} and exit.
- X
- X:x[it][!] [file] Like ":wq", but write only when changes have been
- X made.
- X
- XZZ Store current file, if modified, and exit (same as
- X ":x").
- X
- XIf you write to an existing file (but do not append) while the 'backup' or
- X'writebackup' option is on, a backup of the original file is made. On Unix
- Xsystems the file is copied, on other systems the file is renamed. After the
- Xfile has been successfully written and when the 'writebackup' option is on
- Xand the 'backup' option is off, the backup file is deleted.
- X
- X'backup' 'writebackup' action
- X off off no backup made
- X off on backup made, deleted afterwards
- X on off backup made, not deleted
- X on on backup made, not deleted
- X
- XOn Unix systems:
- XWhen you write to an existing file, that file is truncated and then filled
- Xwith the new text. This means that protection bits, owner and symbolic links
- Xare unmodified. The backup file however, is a new file, owned by the user
- Xwho edited the file. If it is not possible to create the backup file in the
- Xsame directory as the original file, the directory given with the
- X'backupdir' option is used (default: home directory).
- X
- XIf the creation of a backup file fails, the write is not done. If you want
- Xto write anyway add a <!> to the command.
- X
- X
- X5.5 Using the QuickFix option
- X
- XManx's Aztec C compiler on the Amiga has a speciality to speedup the
- Xedit-compile-edit cycle. This is called the QuickFix option. VIM includes
- Xsupport for this handy feature which is almost identical to Manx's editor
- X"Z". What you should do is:
- X
- X- Set the CCEDIT environment variable with the command
- X mset "CCEDIT=vim -e"
- X
- X- Compile with the -qf option. If the compiler finds any errors, Vim is
- Xstarted and the cursor is positioned on the first error. The error message
- Xwill be displayed on the last line. You can go to other errors with the
- Xcommands mentioned below. You can fix the errors and write the file(s).
- X
- X- If you exit Vim normally the compiler will re-compile the same file. If you
- Xexit with the :cq command, the compiler will terminate. Do this if you cannot
- Xfix the error, or if another file needs to be compiled first.
- X
- XThe following commands can be used if you are in QuickFix mode:
- X
- X:cc [nr] Display error [nr]. If [nr] is omitted, the same
- X error is displayed again.
- X
- X:cn Display the next error in the list.
- X
- X:cp Display the previous error in the list.
- X
- X:cq Quit Vim with an error code, so that the compiler
- X will not compile the same file again.
- X
- X:cf Read the error file. This is done automatically when
- X Vim is started with the -e option.
- X
- X:cl List all errors.
- X
- XThe name of the file can be set with the 'errorfile' option. The default is
- X"AztecC.Err". The format of the file is:
- X
- X filename>linenumber:columnnumber:errortype:errornumber:errormessage
- X
- X filename name of the file in which the error was detected
- X linenumber line number where the error was detected
- X columnnumber column number where the error was detected
- X errortype type of the error, normally a single 'E'
- X errornumber number of the error
- X errormessage description of the error
- X
- XIf you have a different compiler you could write a program that translates
- Xthe error messages into this format. Even better, it could start the
- Xcompiler (with make), interpret the output and, when there are any errors,
- Xstart Vim and recompile.
- X
- XThere are some restrictions to the Quickfix option. The compiler only writes
- Xthe first 25 errors to the errorfile (Manx's documentation does not say how
- Xto get more). If you want to find the others, you will have to fix a few
- Xerrors and exit the editor. After recompiling, upto 25 remaining errors
- Xwill be found.
- X
- XIf Vim was started from the compiler the :sh and :! commands will not work,
- Xbecause Vim is then running in the same process as the compiler and these
- Xtwo commands may guru the machine then.
- X
- XIf you insert or delete lines, mostly the correct error location is still
- Xfound because hidden marks are used (Manx's Z editor does not do this).
- XSometimes, when the mark has been deleted for some reason, the message "line
- Xchanged" is shown to warn you that the error location may not be correct. If
- Xyou edit another file the marks are lost and the error locations may not be
- Xcorrect anymore.
- X
- X
- X 6. Cursor motions
- X
- XThese commands move the cursor position. If the new position is off of the
- Xscreen, the screen is scrolled to show the cursor (see also 'scrolljump'
- Xoption).
- X
- XThe motion commands can be used after other commands, called operators, to
- Xhave the command operate on the text that was moved over. That is the text
- Xbetween the cursor position before and after the motion. If the motion
- Xincludes a count and the operator also had a count, the two counts are
- Xmultiplied. For example: "2d3w" deletes six words.
- X The operator either affects whole lines, or the characters between
- Xthe cursor positions. Generally, motions that move between lines affect
- Xlines, and motions that move within a line affect characters. However, there
- Xare some exceptions.
- X The motion is either inclusive or exclusive. When inclusive, the
- Xstart and end positions of the motion are included in the operation. When
- Xexclusive, the last character towards the end of the buffer is not included.
- XLinewise motions are always inclusive.
- X Which motions are linewise, inclusive or exclusive is mentioned
- Xbelow.
- X
- XInstead of first giving the operator and then a motion you can use quoting:
- Xmark the start of the text with <q>, move the cursor to the end of the text
- Xthat is to be affected and then hit the operator. The text between the start
- Xand the cursor position is highlighted, so you can see what text will be
- Xoperated upon. This allows much more freedom, but requires more key strokes
- Xand has limited redo functionality. See the chapter on quoting.
- X
- XIf you want to know where you are in the file use the "CTRL-G" command. If
- Xyou set the 'ruler' option, the cursor position is continuously shown in the
- Xstatus line (which slows down Vim a little).
- X
- XNOTE: Experienced users prefer the hjkl keys because they are always right
- Xunder their fingers. Beginners often prefer the arrow keys, since they do not
- Xrequire memorization of which hjkl key is which. The mnemonic value of hjkl
- Xis clear from looking at the keyboard. Think of j as an arrow pointing
- Xdownwards.
- X
- X6.1 Left-right motions
- X
- Xh or
- X<C_LEFT> or
- XCTRL-H or
- X<BS> [cnt] characters to the left (exclusive).
- X
- Xl or
- X<C_RIGHT> or
- X<SPACE> [cnt] characters to the right (exclusive).
- X
- X0 To the first character of the line (exclusive).
- X
- X^ To the first non-blank character of the line
- X (exclusive).
- X
- X$ To the end of line [cnt] from the cursor (inclusive).
- X
- X| To column [cnt] (inclusive).
- X
- Xf<char> To [cnt]'th occurrence of <char> to the right. The
- X cursor is placed on <char> (inclusive).
- X
- XF<char> To the [cnt]'th occurrence of <char> to the left. The
- X cursor is placed on <char> (inclusive).
- X
- Xt<char> Till before [cnt]'th occurrence of <char> to the
- X right. The cursor is placed on the character left of
- X <char> (inclusive).
- X
- XT<char> Till after [cnt]'th occurrence of <char> to the left.
- X The cursor is placed on the character right of <char>
- END_OF_FILE
- if test 48721 -ne `wc -c <'vim/doc/reference.doc1'`; then
- echo shar: \"'vim/doc/reference.doc1'\" unpacked with wrong size!
- fi
- # end of 'vim/doc/reference.doc1'
- fi
- echo shar: End of archive 22 \(of 23\).
- cp /dev/null ark22isdone
- MISSING=""
- for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 ; do
- if test ! -f ark${I}isdone ; then
- MISSING="${MISSING} ${I}"
- fi
- done
- if test "${MISSING}" = "" ; then
- echo You have unpacked all 23 archives.
- rm -f ark[1-9]isdone ark[1-9][0-9]isdone
- else
- echo You still need to unpack the following archives:
- echo " " ${MISSING}
- fi
- ## End of shell archive.
- exit 0
- -------------8<----------------8<----------------8<---------------8<--------
- Bram Moolenaar | DISCLAIMER: This note does not
- Oce Nederland B.V., Research & Development | necessarily represent the position
- p.o. box 101, 5900 MA Venlo | of Oce-Nederland B.V. Therefore
- The Netherlands phone +31 77 594077 | no liability or responsibility for
- UUCP: mool@oce.nl fax +31 77 595450 | whatever will be accepted.
-
- exit 0 # Just in case...
-