blob: a7a6c2b4783ef35e97b6782c2f819aa81a66eff2 [file] [log] [blame]
Bram Moolenaar6f345a12019-12-17 21:27:18 +01001*vi_diff.txt* For Vim version 8.2. Last change: 2019 Dec 17
Bram Moolenaar071d4272004-06-13 20:20:40 +00002
3
4 VIM REFERENCE MANUAL by Bram Moolenaar
5
6
7Differences between Vim and Vi *vi-differences*
8
Bram Moolenaar25c9c682019-05-05 18:13:34 +02009This file lists the differences between Vim and Vi/Ex and gives an overview of
10what is in Vim that is not in Vi.
Bram Moolenaar071d4272004-06-13 20:20:40 +000011
12Vim is mostly POSIX 1003.2-1 compliant. The only command known to be missing
13is ":open". There are probably a lot of small differences (either because Vim
14is missing something or because Posix is beside the mark).
15
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +0000161. Simulated command |simulated-command|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000172. Missing options |missing-options|
183. Limits |limits|
194. The most interesting additions |vim-additions|
205. Other vim features |other-features|
Bram Moolenaar6c60f472019-04-28 16:00:35 +0200216. Supported Vi features |vi-features|
227. Command-line arguments |cmdline-arguments|
238. POSIX compliance |posix-compliance|
Bram Moolenaar071d4272004-06-13 20:20:40 +000024
25==============================================================================
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +0000261. Simulated command *simulated-command*
Bram Moolenaar071d4272004-06-13 20:20:40 +000027
Bram Moolenaardd2a3cd2007-05-05 17:10:09 +000028This command is in Vi, but Vim only simulates it:
Bram Moolenaar071d4272004-06-13 20:20:40 +000029
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +000030 *:o* *:op* *:open*
31:[range]o[pen] Works like |:visual|: end Ex mode.
32 {Vi: start editing in open mode}
33
34:[range]o[pen] /pattern/ As above, additionally move the cursor to the
35 column where "pattern" matches in the cursor
36 line.
37
38Vim does not support open mode, since it's not really useful. For those
39situations where ":open" would start open mode Vim will leave Ex mode, which
40allows executing the same commands, but updates the whole screen instead of
41only one line.
Bram Moolenaar071d4272004-06-13 20:20:40 +000042
43==============================================================================
442. Missing options *missing-options*
45
46These options are in the Unix Vi, but not in Vim. If you try to set one of
47them you won't get an error message, but the value is not used and cannot be
48printed.
49
50autoprint (ap) boolean (default on) *'autoprint'* *'ap'*
51beautify (bf) boolean (default off) *'beautify'* *'bf'*
52flash (fl) boolean (default ??) *'flash'* *'fl'*
53graphic (gr) boolean (default off) *'graphic'* *'gr'*
54hardtabs (ht) number (default 8) *'hardtabs'* *'ht'*
55 number of spaces that a <Tab> moves on the display
56mesg boolean (default on) *'mesg'*
57novice boolean (default off) *'novice'*
58open boolean (default on) *'open'*
59optimize (op) boolean (default off) *'optimize'* *'op'*
Bram Moolenaar071d4272004-06-13 20:20:40 +000060redraw boolean (default off) *'redraw'*
61slowopen (slow) boolean (default off) *'slowopen'* *'slow'*
62sourceany boolean (default off) *'sourceany'*
Bram Moolenaar071d4272004-06-13 20:20:40 +000063w300 number (default 23) *'w300'*
64w1200 number (default 23) *'w1200'*
65w9600 number (default 23) *'w9600'*
66
Bram Moolenaar2e693a82019-10-16 22:35:02 +020067Vi did not allow for changing the termcap entries, you would have to exit Vi,
68edit the termcap entry and try again. Vim has the |terminal-options|.
69
Bram Moolenaar071d4272004-06-13 20:20:40 +000070==============================================================================
713. Limits *limits*
72
73Vim has only a few limits for the files that can be edited {Vi: can not handle
74<Nul> characters and characters above 128, has limited line length, many other
75limits}.
76 *E340*
77Maximum line length On machines with 16-bit ints (Amiga and MS-DOS real
78 mode): 32767, otherwise 2147483647 characters.
79 Longer lines are split.
80Maximum number of lines 2147483647 lines.
81Maximum file size 2147483647 bytes (2 Gbyte) when a long integer is
82 32 bits. Much more for 64 bit longs. Also limited
83 by available disk space for the |swap-file|.
84 *E75*
85Length of a file path Unix and Win32: 1024 characters, otherwise 256
86 characters (or as much as the system supports).
87Length of an expanded string option
88 Unix and Win32: 1024 characters, otherwise 256
89 characters
90Maximum display width Unix and Win32: 1024 characters, otherwise 255
91 characters
92Maximum lhs of a mapping 50 characters.
Bram Moolenaar4770d092006-01-12 23:22:24 +000093Number of different highlighting types: over 30000
Bram Moolenaar5302d9e2011-09-14 17:55:08 +020094Range of a Number variable: -2147483648 to 2147483647 (might be more on 64
95 bit systems)
Bram Moolenaar4a748032010-09-30 21:47:56 +020096Maximum length of a line in a tags file: 512 bytes.
Bram Moolenaar071d4272004-06-13 20:20:40 +000097
98Information for undo and text in registers is kept in memory, thus when making
99(big) changes the amount of (virtual) memory available limits the number of
100undo levels and the text that can be kept in registers. Other things are also
101kept in memory: Command-line history, error messages for Quickfix mode, etc.
102
103Memory usage limits
104-------------------
105
106The option 'maxmem' ('mm') is used to set the maximum memory used for one
107buffer (in kilobytes). 'maxmemtot' is used to set the maximum memory used for
108all buffers (in kilobytes). The defaults depend on the system used. For the
109Amiga and MS-DOS, 'maxmemtot' is set depending on the amount of memory
Bram Moolenaar18144c82006-04-12 21:52:12 +0000110available.
111These are not hard limits, but tell Vim when to move text into a swap file.
112If you don't like Vim to swap to a file, set 'maxmem' and 'maxmemtot' to a
113very large value. The swap file will then only be used for recovery. If you
114don't want a swap file at all, set 'updatecount' to 0, or use the "-n"
115argument when starting Vim.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000116
117==============================================================================
1184. The most interesting additions *vim-additions*
119
120Vi compatibility. |'compatible'|
121 Although Vim is 99% Vi compatible, some things in Vi can be
122 considered to be a bug, or at least need improvement. But still, Vim
123 starts in a mode which behaves like the "real" Vi as much as possible.
124 To make Vim behave a little bit better, try resetting the 'compatible'
125 option:
126 :set nocompatible
127 Or start Vim with the "-N" argument:
128 vim -N
Bram Moolenaar18144c82006-04-12 21:52:12 +0000129 Vim starts with 'nocompatible' automatically if you have a .vimrc
130 file. See |startup|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000131 The 'cpoptions' option can be used to set Vi compatibility on/off for
132 a number of specific items.
133
134Support for different systems.
135 Vim can be used on:
136 - All Unix systems (it works on all systems it was tested on, although
137 the GUI and Perl interface may not work everywhere).
138 - Amiga (500, 1000, 1200, 2000, 3000, 4000, ...).
Bram Moolenaar6f345a12019-12-17 21:27:18 +0100139 - Windows NT, with support for long file names.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000140 - VMS
141 - BeOS
142 - Macintosh
143 - Risc OS
144 - IBM OS/390
Bram Moolenaar18144c82006-04-12 21:52:12 +0000145 Note that on some systems features need to be disabled to reduce
146 resource usage, esp. on MS-DOS. For some outdated systems you need to
147 use an older Vim version.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000148
Bram Moolenaardc1f1642016-08-16 18:33:43 +0200149Multi level persistent undo. |undo|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000150 'u' goes backward in time, 'CTRL-R' goes forward again. Set option
151 'undolevels' to the number of changes to be remembered (default 1000).
Bram Moolenaar7cba6c02013-09-05 22:13:31 +0200152 Set 'undolevels' to 0 for a Vi-compatible one level undo. Set it to
Bram Moolenaar071d4272004-06-13 20:20:40 +0000153 -1 for no undo at all.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000154 When all changes in a buffer have been undone, the buffer is not
155 considered changed anymore. You can exit it with :q, without <!>.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000156 When undoing a few changes and then making a new change Vim will
157 create a branch in the undo tree. This means you can go back to any
Bram Moolenaar143c38c2007-05-10 16:41:10 +0000158 state of the text, there is no risk of a change causing text to be
Bram Moolenaar18144c82006-04-12 21:52:12 +0000159 lost forever. |undo-tree|
Bram Moolenaardc1f1642016-08-16 18:33:43 +0200160 The undo information is stored in a file when the 'undofile' option is
161 set. This means you can exit Vim, start Vim on a previously edited
162 file and undo changes that were made before exiting Vim.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000163
Bram Moolenaar18144c82006-04-12 21:52:12 +0000164Graphical User Interface (GUI). |gui|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000165 Included support for GUI: menu's, mouse, scrollbars, etc. You can
166 define your own menus. Better support for CTRL/SHIFT/ALT keys in
167 combination with special keys and mouse. Supported for various
168 platforms, such as X11 (with Motif and Athena interfaces), GTK, Win32
169 (Windows 95 and later), BeOS, Amiga and Macintosh.
170
171Multiple windows and buffers. |windows.txt|
172 Vim can split the screen into several windows, each editing a
173 different buffer or the same buffer at a different location. Buffers
174 can still be loaded (and changed) but not displayed in a window. This
175 is called a hidden buffer. Many commands and options have been added
176 for this facility.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000177 Vim can also use multiple tab pages, each with one or more windows. A
178 line with tab labels can be used to quickly switch between these pages.
179 |tab-page|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000180
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200181Terminal window. |:terminal|
182 Vim can create a window in which a terminal emulator runs. This can
183 be used to execute an arbitrary command, a shell or a debugger.
184
Bram Moolenaar071d4272004-06-13 20:20:40 +0000185Syntax highlighting. |:syntax|
186 Vim can highlight keywords, patterns and other things. This is
Bram Moolenaar18144c82006-04-12 21:52:12 +0000187 defined by a number of |:syntax| commands, and can be made to
Bram Moolenaar071d4272004-06-13 20:20:40 +0000188 highlight most languages and file types. A number of files are
189 included for highlighting the most common languages, like C, C++,
190 Java, Pascal, Makefiles, shell scripts, etc. The colors used for
191 highlighting can be defined for ordinary terminals, color terminals
Bram Moolenaar18144c82006-04-12 21:52:12 +0000192 and the GUI with the |:highlight| command. A convenient way to do
193 this is using a |:colorscheme| command.
194 The highlighted text can be exported as HTML. |convert-to-HTML|
195 Other items that can be highlighted are matches with the search string
196 |'hlsearch'|, matching parens |matchparen| and the cursor line and
197 column |'cursorline'| |'cursorcolumn'|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000198
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200199Text properties |textprop.txt|
200 Vim supports highlighting text by a plugin. Property types can be
Bram Moolenaar68e65602019-05-26 21:33:31 +0200201 specified with |prop_type_add()| and properties can be placed with
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200202 |prop_add()|.
203
Bram Moolenaar18144c82006-04-12 21:52:12 +0000204Spell checking. |spell|
205 When the 'spell' option is set Vim will highlight spelling mistakes.
Bram Moolenaar9b451252012-08-15 17:43:31 +0200206 About 50 languages are currently supported, selected with the
Bram Moolenaarf2330482008-06-24 20:19:36 +0000207 'spelllang' option. In source code only comments and strings are
Bram Moolenaar18144c82006-04-12 21:52:12 +0000208 checked for spelling.
209
210Folding. |folding|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000211 A range of lines can be shown as one "folded" line. This allows
212 overviewing a file and moving blocks of text around quickly.
213 Folds can be created manually, from the syntax of the file, by indent,
214 etc.
215
Bram Moolenaar18144c82006-04-12 21:52:12 +0000216Diff mode. |diff|
217 Vim can show two versions of a file with the differences highlighted.
218 Parts of the text that are equal are folded away. Commands can be
219 used to move text from one version to the other.
220
221Plugins. |add-plugin|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000222 The functionality can be extended by dropping a plugin file in the
223 right directory. That's an easy way to start using Vim scripts
224 written by others. Plugins can be for all kind of files, or
225 specifically for a filetype.
Bram Moolenaardc1f1642016-08-16 18:33:43 +0200226 Packages make this even easier. |packages|
227
228Asynchronous communication and timers. |channel| |job| |timer|
229 Vim can exchange messages with other processes in the background.
230 This makes it possible to have servers do work and send back the
231 results to Vim. |channel|
232 Vim can start a job, communicate with it and stop it. |job|
233 Timers can fire once or repeatedly and invoke a function to do any
234 work. |timer|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000235
236Repeat a series of commands. |q|
Bram Moolenaar18144c82006-04-12 21:52:12 +0000237 "q{c}" starts recording typed characters into named register {c}.
238 A subsequent "q" stops recording. The register can then be executed
239 with the "@{c}" command. This is very useful to repeat a complex
240 action.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000241
242Flexible insert mode. |ins-special-special|
243 The arrow keys can be used in insert mode to move around in the file.
244 This breaks the insert in two parts as far as undo and redo is
245 concerned.
246
Bram Moolenaar18144c82006-04-12 21:52:12 +0000247 CTRL-O can be used to execute a single Normal mode command. This is
248 almost the same as hitting <Esc>, typing the command and doing |a|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000249
250Visual mode. |Visual-mode|
Bram Moolenaar18144c82006-04-12 21:52:12 +0000251 Visual mode can be used to first highlight a piece of text and then
252 give a command to do something with it. This is an (easy to use)
253 alternative to first giving the operator and then moving to the end of
254 the text to be operated upon.
255 |v| and |V| are used to start Visual mode. |v| works on characters
256 and |V| on lines. Move the cursor to extend the Visual area. It is
257 shown highlighted on the screen. By typing "o" the other end of the
258 Visual area can be moved. The Visual area can be affected by an
259 operator:
Bram Moolenaar071d4272004-06-13 20:20:40 +0000260 d delete
261 c change
262 y yank
263 > or < insert or delete indent
264 ! filter through external program
265 = filter through indent
Bram Moolenaar18144c82006-04-12 21:52:12 +0000266 : start |:| command for the Visual lines.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000267 gq format text to 'textwidth' columns
268 J join lines
269 ~ swap case
270 u make lowercase
271 U make uppercase
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200272 {Vi has no Visual mode, the name "visual" is used for Normal mode, to
273 distinguish it from Ex mode}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000274
275Block operators. |visual-block|
Bram Moolenaar18144c82006-04-12 21:52:12 +0000276 With Visual mode a rectangular block of text can be selected. Start
277 Visual mode with CTRL-V. The block can be deleted ("d"), yanked ("y")
278 or its case can be changed ("~", "u" and "U"). A deleted or yanked
279 block can be put into the text with the "p" and "P" commands.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000280
Bram Moolenaar18144c82006-04-12 21:52:12 +0000281Help system. |:help|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000282 Help is displayed in a window. The usual commands can be used to
283 move around, search for a string, etc. Tags can be used to jump
Bram Moolenaar18144c82006-04-12 21:52:12 +0000284 around in the help files, just like hypertext links. The |:help|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000285 command takes an argument to quickly jump to the info on a subject.
286 <F1> is the quick access to the help system. The name of the help
287 index file can be set with the 'helpfile' option.
288
289Command-line editing and history. |cmdline-editing|
290 You can insert or delete at any place in the command-line using the
291 cursor keys. The right/left cursor keys can be used to move
292 forward/backward one character. The shifted right/left cursor keys
293 can be used to move forward/backward one word. CTRL-B/CTRL-E can be
294 used to go to the begin/end of the command-line.
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200295 {Vi: can only alter the last character in the line}
296 {Vi: when hitting <Esc> the command-line is executed. This is
297 unexpected for most people; therefore it was changed in Vim. But when
298 the <Esc> is part of a mapping, the command-line is executed. If you
299 want the Vi behaviour also when typing <Esc>, use ":cmap ^V<Esc>
300 ^V^M"}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000301 |cmdline-history|
302 The command-lines are remembered. The up/down cursor keys can be used
303 to recall previous command-lines. The 'history' option can be set to
304 the number of lines that will be remembered. There is a separate
305 history for commands and for search patterns.
306
307Command-line completion. |cmdline-completion|
308 While entering a command-line (on the bottom line of the screen)
309 <Tab> can be typed to complete
310 what example ~
311 - command :e<Tab>
312 - tag :ta scr<Tab>
313 - option :set sc<Tab>
314 - option value :set hf=<Tab>
315 - file name :e ve<Tab>
316 - etc.
317
318 If there are multiple matches, CTRL-N (next) and CTRL-P (previous)
319 will walk through the matches. <Tab> works like CTRL-N, but wraps
320 around to the first match.
321
322 The 'wildchar' option can be set to the character for command-line
323 completion, <Tab> is the default. CTRL-D can be typed after an
324 (incomplete) wildcard; all matches will be listed. CTRL-A will insert
325 all matches. CTRL-L will insert the longest common part of the
326 matches.
327
Bram Moolenaar18144c82006-04-12 21:52:12 +0000328Insert-mode completion. |ins-completion|
329 In Insert mode the CTRL-N and CTRL-P keys can be used to complete a
330 word that appears elsewhere. |i_CTRL-N|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000331 With CTRL-X another mode is entered, through which completion can be
332 done for:
333 |i_CTRL-X_CTRL-F| file names
334 |i_CTRL-X_CTRL-K| words from 'dictionary' files
335 |i_CTRL-X_CTRL-T| words from 'thesaurus' files
336 |i_CTRL-X_CTRL-I| words from included files
337 |i_CTRL-X_CTRL-L| whole lines
338 |i_CTRL-X_CTRL-]| words from the tags file
339 |i_CTRL-X_CTRL-D| definitions or macros
Bram Moolenaar18144c82006-04-12 21:52:12 +0000340 |i_CTRL-X_CTRL-O| Omni completion: clever completion
341 specifically for a file type
342 etc.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000343
Bram Moolenaar18144c82006-04-12 21:52:12 +0000344Long line support. |'wrap'| |'linebreak'|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000345 If the 'wrap' option is off, long lines will not wrap and only part
346 of them will be shown. When the cursor is moved to a part that is not
347 shown, the screen will scroll horizontally. The minimum number of
Bram Moolenaar18144c82006-04-12 21:52:12 +0000348 columns to scroll can be set with the 'sidescroll' option. The |zh|
349 and |zl| commands can be used to scroll sideways.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000350 Alternatively, long lines are broken in between words when the
351 'linebreak' option is set. This allows editing a single-line
352 paragraph conveniently (e.g. when the text is later read into a DTP
Bram Moolenaar18144c82006-04-12 21:52:12 +0000353 program). Move the cursor up/down with the |gk| and |gj| commands.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000354
355Text formatting. |formatting|
356 The 'textwidth' option can be used to automatically limit the line
357 length. This supplements the 'wrapmargin' option of Vi, which was not
Bram Moolenaar18144c82006-04-12 21:52:12 +0000358 very useful. The |gq| operator can be used to format a piece of text
359 (for example, |gqap| formats the current paragraph). Commands for
360 text alignment: |:center|, |:left| and |:right|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000361
Bram Moolenaar18144c82006-04-12 21:52:12 +0000362Extended search patterns. |pattern|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000363 There are many extra items to match various text items. Examples:
364 A "\n" can be used in a search pattern to match a line break.
365 "x\{2,4}" matches "x" 2 to 4 times.
366 "\s" matches a white space character.
367
Bram Moolenaar18144c82006-04-12 21:52:12 +0000368Directory, remote and archive browsing. |netrw|
369 Vim can browse the file system. Simply edit a directory. Move around
370 in the list with the usual commands and press <Enter> to go to the
371 directory or file under the cursor.
372 This also works for remote files over ftp, http, ssh, etc.
373 Zip and tar archives can also be browsed. |tar| |zip|
374
Bram Moolenaar071d4272004-06-13 20:20:40 +0000375Edit-compile-edit speedup. |quickfix|
Bram Moolenaar18144c82006-04-12 21:52:12 +0000376 The |:make| command can be used to run the compilation and jump to the
377 first error. A file with compiler error messages is interpreted. Vim
378 jumps to the first error.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000379
380 Each line in the error file is scanned for the name of a file, line
381 number and error message. The 'errorformat' option can be set to a
382 list of scanf-like strings to handle output from many compilers.
383
Bram Moolenaar18144c82006-04-12 21:52:12 +0000384 The |:cn| command can be used to jump to the next error.
385 |:cl| lists all the error messages. Other commands are available.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000386 The 'makeef' option has the name of the file with error messages.
387 The 'makeprg' option contains the name of the program to be executed
Bram Moolenaar18144c82006-04-12 21:52:12 +0000388 with the |:make| command.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000389 The 'shellpipe' option contains the string to be used to put the
390 output of the compiler into the errorfile.
391
Bram Moolenaar18144c82006-04-12 21:52:12 +0000392Finding matches in files. |:vimgrep|
393 Vim can search for a pattern in multiple files. This uses the
394 advanced Vim regexp pattern, works on all systems and also works to
395 search in compressed files.
396
397Improved indenting for programs. |'cindent'|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000398 When the 'cindent' option is on the indent of each line is
399 automatically adjusted. C syntax is mostly recognized. The indent
400 for various styles can be set with 'cinoptions'. The keys to trigger
401 indenting can be set with 'cinkeys'.
402
403 Comments can be automatically formatted. The 'comments' option can be
404 set to the characters that start and end a comment. This works best
405 for C code, but also works for e-mail (">" at start of the line) and
Bram Moolenaar18144c82006-04-12 21:52:12 +0000406 other types of text. The |=| operator can be used to re-indent
Bram Moolenaar071d4272004-06-13 20:20:40 +0000407 lines.
408
Bram Moolenaar18144c82006-04-12 21:52:12 +0000409 For many other languages an indent plugin is present to support
410 automatic indenting. |30.3|
411
412Searching for words in included files. |include-search|
413 The |[i| command can be used to search for a match of the word under
Bram Moolenaar071d4272004-06-13 20:20:40 +0000414 the cursor in the current and included files. The 'include' option
Bram Moolenaarc236c162008-07-13 17:41:49 +0000415 can be set to a pattern that describes a command to include a file
Bram Moolenaar071d4272004-06-13 20:20:40 +0000416 (the default is for C programs).
Bram Moolenaar18144c82006-04-12 21:52:12 +0000417 The |[I| command lists all matches, the |[_CTRL-I| command jumps to
Bram Moolenaar071d4272004-06-13 20:20:40 +0000418 a match.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000419 The |[d|, |[D| and |[_CTRL-D| commands do the same, but only for
Bram Moolenaar071d4272004-06-13 20:20:40 +0000420 lines where the pattern given with the 'define' option matches.
421
Bram Moolenaar18144c82006-04-12 21:52:12 +0000422Automatic commands. |autocommand|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000423 Commands can be automatically executed when reading a file, writing a
424 file, jumping to another buffer, etc., depending on the file name.
425 This is useful to set options and mappings for C programs,
426 documentation, plain text, e-mail, etc. This also makes it possible
427 to edit compressed files.
428
Bram Moolenaar18144c82006-04-12 21:52:12 +0000429Scripts and Expressions. |expression|
430 Commands have been added to form up a powerful script language.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000431 |:if| Conditional execution, which can be used for example
432 to set options depending on the value of $TERM.
433 |:while| Repeat a number of commands.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000434 |:for| Loop over a list.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000435 |:echo| Print the result of an expression.
436 |:let| Assign a value to an internal variable, option, etc.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000437 Variable types are Number, String, List and Dictionary.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000438 |:execute| Execute a command formed by an expression.
Bram Moolenaar18144c82006-04-12 21:52:12 +0000439 |:try| Catch exceptions.
440 etc., etc. See |eval|.
441 Debugging and profiling are supported. |debug-scripts| |profile|
442 If this is not enough, an interface is provided to |Python|, |Ruby|,
Bram Moolenaar0ba04292010-07-14 23:23:17 +0200443 |Tcl|, |Lua|, |Perl| and |MzScheme|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000444
Bram Moolenaar18144c82006-04-12 21:52:12 +0000445Viminfo. |viminfo-file|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000446 The command-line history, marks and registers can be stored in a file
447 that is read on startup. This can be used to repeat a search command
448 or command-line command after exiting and restarting Vim. It is also
Bram Moolenaar18144c82006-04-12 21:52:12 +0000449 possible to jump right back to where the last edit stopped with |'0|.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000450 The 'viminfo' option can be set to select which items to store in the
451 .viminfo file. This is off by default.
452
Bram Moolenaar18144c82006-04-12 21:52:12 +0000453Printing. |printing|
454 The |:hardcopy| command sends text to the printer. This can include
455 syntax highlighting.
456
457Mouse support. |mouse-using|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000458 The mouse is supported in the GUI version, in an xterm for Unix, for
Bram Moolenaarf2330482008-06-24 20:19:36 +0000459 BSDs with sysmouse, for Linux with gpm, for MS-DOS, and Win32. It
460 can be used to position the cursor, select the visual area, paste a
461 register, etc.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000462
Bram Moolenaar18144c82006-04-12 21:52:12 +0000463Usage of key names. |<>| |key-notation|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000464 Special keys now all have a name like <Up>, <End>, etc.
465 This name can be used in mappings, to make it easy to edit them.
466
Bram Moolenaar18144c82006-04-12 21:52:12 +0000467Editing binary files. |edit-binary|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000468 Vim can edit binary files. You can change a few characters in an
469 executable file, without corrupting it. Vim doesn't remove NUL
470 characters (they are represented as <NL> internally).
471 |-b| command-line argument to start editing a binary file
Bram Moolenaar18144c82006-04-12 21:52:12 +0000472 |'binary'| Option set by |-b|. Prevents adding an <EOL> for the
Bram Moolenaar071d4272004-06-13 20:20:40 +0000473 last line in the file.
474
Bram Moolenaar18144c82006-04-12 21:52:12 +0000475Multi-language support. |multi-lang|
Bram Moolenaar071d4272004-06-13 20:20:40 +0000476 Files in double-byte or multi-byte encodings can be edited. There is
477 UTF-8 support to be able to edit various languages at the same time,
478 without switching fonts. |UTF-8|
479 Messages and menus are available in different languages.
480
Bram Moolenaar18144c82006-04-12 21:52:12 +0000481Move cursor beyond lines.
482 When the 'virtualedit' option is set the cursor can move all over the
483 screen, also where there is no text. This is useful to edit tables
484 and figures easily.
485
Bram Moolenaar071d4272004-06-13 20:20:40 +0000486==============================================================================
4875. Other vim features *other-features*
488
489A random collection of nice extra features.
490
491
492When Vim is started with "-s scriptfile", the characters read from
493"scriptfile" are treated as if you typed them. If end of file is reached
494before the editor exits, further characters are read from the console.
495
496The "-w" option can be used to record all typed characters in a script file.
497This file can then be used to redo the editing, possibly on another file or
498after changing some commands in the script file.
499
500The "-o" option opens a window for each argument. "-o4" opens four windows.
501
502Vi requires several termcap entries to be able to work full-screen. Vim only
503requires the "cm" entry (cursor motion).
504
505
506In command mode:
507
508When the 'showcmd' option is set, the command characters are shown in the last
509line of the screen. They are removed when the command is finished.
510
511If the 'ruler' option is set, the current cursor position is shown in the
512last line of the screen.
513
514"U" still works after having moved off the last changed line and after "u".
515
516Characters with the 8th bit set are displayed. The characters between '~' and
5170xa0 are displayed as "~?", "~@", "~A", etc., unless they are included in the
518'isprint' option.
519
520"][" goes to the next ending of a C function ('}' in column 1).
521"[]" goes to the previous ending of a C function ('}' in column 1).
522
523"]f", "[f" and "gf" start editing the file whose name is under the cursor.
524CTRL-W f splits the window and starts editing the file whose name is under
525the cursor.
526
527"*" searches forward for the identifier under the cursor, "#" backward.
528"K" runs the program defined by the 'keywordprg' option, with the identifier
529under the cursor as argument.
530
531"%" can be preceded with a count. The cursor jumps to the line that
532percentage down in the file. The normal "%" function to jump to the matching
533brace skips braces inside quotes.
534
535With the CTRL-] command, the cursor may be in the middle of the identifier.
536
537The used tags are remembered. Commands that can be used with the tag stack
538are CTRL-T, ":pop" and ":tag". ":tags" lists the tag stack.
539
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200540Vi uses 'wrapscan' when searching for a tag. When jumping to a tag Vi starts
541searching in line 2 of another file. It does not find a tag in line 1 of
542another file when 'wrapscan' is not set.
543
Bram Moolenaar071d4272004-06-13 20:20:40 +0000544The 'tags' option can be set to a list of tag file names. Thus multiple
545tag files can be used. For file names that start with "./", the "./" is
546replaced with the path of the current file. This makes it possible to use a
547tags file in the same directory as the file being edited.
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200548{Vi: always uses binary search in some versions}
549{Vi does not have the security prevention for commands in tag files}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000550
551Previously used file names are remembered in the alternate file name list.
552CTRL-^ accepts a count, which is an index in this list.
553":files" command shows the list of alternate file names.
554"#<N>" is replaced with the <N>th alternate file name in the list.
555"#<" is replaced with the current file name without extension.
556
557Search patterns have more features. The <NL> character is seen as part of the
558search pattern and the substitute string of ":s". Vi sees it as the end of
559the command.
560
561Searches can put the cursor on the end of a match and may include a character
562offset.
563
564Count added to "~", ":next", ":Next", "n" and "N".
565
566The command ":next!" with 'autowrite' set does not write the file. In vi the
567file was written, but this is considered to be a bug, because one does not
568expect it and the file is not written with ":rewind!".
569
570In Vi when entering a <CR> in replace mode deletes a character only when 'ai'
571is set (but does not show it until you hit <Esc>). Vim always deletes a
572character (and shows it immediately).
573
574Added :wnext command. Same as ":write" followed by ":next".
575
576The ":w!" command always writes, also when the file is write protected. In Vi
Bram Moolenaar26df0922014-02-23 23:39:13 +0100577you would have to do ":!chmod +w %:S" and ":set noro".
Bram Moolenaar071d4272004-06-13 20:20:40 +0000578
579When 'tildeop' has been set, "~" is an operator (must be followed by a
580movement command).
581
582With the "J" (join) command you can reset the 'joinspaces' option to have only
583one space after a period (Vi inserts two spaces).
584
585"cw" can be used to change white space formed by several characters (Vi is
586confusing: "cw" only changes one space, while "dw" deletes all white space).
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200587{Vi: "cw" when on a blank followed by other blanks changes only the first
588blank; this is probably a bug, because "dw" deletes all the blanks}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000589
590"o" and "O" accept a count for repeating the insert (Vi clears a part of
591display).
592
593Flags after Ex commands not supported (no plans to include it).
594
595On non-UNIX systems ":cd" command shows current directory instead of going to
596the home directory (there isn't one). ":pwd" prints the current directory on
597all systems.
598
599After a ":cd" command the file names (in the argument list, opened files)
600still point to the same files. In Vi ":cd" is not allowed in a changed file;
601otherwise the meaning of file names change.
602
603":source!" command reads Vi commands from a file.
604
605":mkexrc" command writes current modified options and mappings to a ".exrc"
606file. ":mkvimrc" writes to a ".vimrc" file.
607
608No check for "tail recursion" with mappings. This allows things like
609":map! foo ^]foo".
610
611When a mapping starts with number, vi loses the count typed before it (e.g.
612when using the mapping ":map g 4G" the command "7g" goes to line 4). This is
613considered a vi bug. Vim concatenates the counts (in the example it becomes
614"74G"), as most people would expect.
615
616The :put! command inserts the contents of a register above the current line.
617
618The "p" and "P" commands of vi cannot be repeated with "." when the putted
619text is less than a line. In Vim they can always be repeated.
620
621":noremap" command can be used to enter a mapping that will not be remapped.
622This is useful to exchange the meaning of two keys. ":cmap", ":cunmap" and
623":cnoremap" can be used for mapping in command-line editing only. ":imap",
624":iunmap" and ":inoremap" can be used for mapping in insert mode only.
625Similar commands exist for abbreviations: ":noreabbrev", ":iabbrev"
626":cabbrev", ":iunabbrev", ":cunabbrev", ":inoreabbrev", ":cnoreabbrev".
627
628In Vi the command ":map foo bar" would remove a previous mapping
629":map bug foo". This is considered a bug, so it is not included in Vim.
630":unmap! foo" does remove ":map! bug foo", because unmapping would be very
631difficult otherwise (this is vi compatible).
632
633The ':' register contains the last command-line.
634The '%' register contains the current file name.
635The '.' register contains the last inserted text.
636
637":dis" command shows the contents of the yank registers.
638
639CTRL-O/CTRL-I can be used to jump to older/newer positions. These are the
640same positions as used with the '' command, but may be in another file. The
641":jumps" command lists the older positions.
642
643If the 'shiftround' option is set, an indent is rounded to a multiple of
644'shiftwidth' with ">" and "<" commands.
645
646The 'scrolljump' option can be set to the minimum number of lines to scroll
647when the cursor gets off the screen. Use this when scrolling is slow.
648
649The 'scrolloff' option can be set to the minimum number of lines to keep
650above and below the cursor. This gives some context to where you are
651editing. When set to a large number the cursor line is always in the middle
652of the window.
653
654Uppercase marks can be used to jump between files. The ":marks" command lists
655all currently set marks. The commands "']" and "`]" jump to the end of the
656previous operator or end of the text inserted with the put command. "'[" and
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200657"`[" do jump to the start. {Vi: no uppercase marks}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000658
659The 'shelltype' option can be set to reflect the type of shell used on the
660Amiga.
661
662The 'highlight' option can be set for the highlight mode to be used for
663several commands.
664
665The CTRL-A (add) and CTRL-X (subtract) commands are new. The count to the
666command (default 1) is added to/subtracted from the number at or after the
667cursor. That number may be decimal, octal (starts with a '0') or hexadecimal
668(starts with '0x'). Very useful in macros.
669
670With the :set command the prefix "inv" can be used to invert boolean options.
671
672In both Vi and Vim you can create a line break with the ":substitute" command
673by using a CTRL-M. For Vi this means you cannot insert a real CTRL-M in the
674text. With Vim you can put a real CTRL-M in the text by preceding it with a
675CTRL-V.
676
677
678In Insert mode:
679
680If the 'revins' option is set, insert happens backwards. This is for typing
681Hebrew. When inserting normal characters the cursor will not be shifted and
682the text moves rightwards. Backspace, CTRL-W and CTRL-U will also work in
683the opposite direction. CTRL-B toggles the 'revins' option. In replace mode
684'revins' has no effect. Only when enabled at compile time.
685
686The backspace key can be used just like CTRL-D to remove auto-indents.
687
688You can backspace, CTRL-U and CTRL-W over line breaks if the 'backspace' (bs)
689option includes "eol". You can backspace over the start of insert if the
690'backspace' option includes "start".
691
Bram Moolenaar9b451252012-08-15 17:43:31 +0200692When the 'paste' option is set, a few options are reset and mapping in insert
Bram Moolenaar071d4272004-06-13 20:20:40 +0000693mode and abbreviation are disabled. This allows for pasting text in windowing
694systems without unexpected results. When the 'paste' option is reset, the old
695option values are restored.
696
697CTRL-T/CTRL-D always insert/delete an indent in the current line, no matter
698what column the cursor is in.
699
700CTRL-@ (insert previously inserted text) works always (Vi: only when typed as
701first character).
702
703CTRL-A works like CTRL-@ but does not leave insert mode.
704
Bram Moolenaar5be4cee2019-09-27 19:34:08 +0200705CTRL-R {register} can be used to insert the contents of a register.
Bram Moolenaar071d4272004-06-13 20:20:40 +0000706
707When the 'smartindent' option is set, C programs will be better auto-indented.
708With 'cindent' even more.
709
710CTRL-Y and CTRL-E can be used to copy a character from above/below the
711current cursor position.
712
713After CTRL-V you can enter a three digit decimal number. This byte value is
714inserted in the text as a single character. Useful for international
715characters that are not on your keyboard.
716
717When the 'expandtab' (et) option is set, a <Tab> is expanded to the
718appropriate number of spaces.
719
720The window always reflects the contents of the buffer (Vi does not do this
721when changing text and in some other cases).
722
723If Vim is compiled with DIGRAPHS defined, digraphs are supported. A set of
724normal digraphs is included. They are shown with the ":digraph" command.
725More can be added with ":digraph {char1}{char2} {number}". A digraph is
726entered with "CTRL-K {char1} {char2}" or "{char1} BS {char2}" (only when
727'digraph' option is set).
728
729When repeating an insert, e.g. "10atest <Esc>" vi would only handle wrapmargin
730for the first insert. Vim does it for all.
731
732A count to the "i" or "a" command is used for all the text. Vi uses the count
733only for one line. "3iabc<NL>def<Esc>" would insert "abcabcabc<NL>def" in Vi
734but "abc<NL>defabc<NL>defabc<NL>def" in Vim.
735
736
737In Command-line mode:
738
Bram Moolenaar4499d2e2005-04-15 20:41:38 +0000739<Esc> terminates the command-line without executing it. In vi the command
Bram Moolenaar071d4272004-06-13 20:20:40 +0000740line would be executed, which is not what most people expect (hitting <Esc>
741should always get you back to command mode). To avoid problems with some
742obscure macros, an <Esc> in a macro will execute the command. If you want a
743typed <Esc> to execute the command like vi does you can fix this with
744 ":cmap ^V<Esc> ^V<CR>"
745
746General:
747
748The 'ttimeout' option is like 'timeout', but only works for cursor and
749function keys, not for ordinary mapped characters. The 'timeoutlen' option
750gives the number of milliseconds that is waited for. If the 'esckeys' option
751is not set, cursor and function keys that start with <Esc> are not recognized
752in insert mode.
753
754There is an option for each terminal string. Can be used when termcap is not
755supported or to change individual strings.
756
757The 'fileformat' option can be set to select the <EOL>: "dos" <CR><NL>, "unix"
758<NL> or "mac" <CR>.
759When the 'fileformats' option is not empty, Vim tries to detect the type of
760<EOL> automatically. The 'fileformat' option is set accordingly.
761
762On systems that have no job control (older Unix systems and non-Unix systems)
763the CTRL-Z, ":stop" or ":suspend" command starts a new shell.
764
765If Vim is started on the Amiga without an interactive window for output, a
766window is opened (and :sh still works). You can give a device to use for
767editing with the |-d| argument, e.g. "-d con:20/20/600/150".
768
769The 'columns' and 'lines' options are used to set or get the width and height
770of the display.
771
772Option settings are read from the first and last few lines of the file.
773Option 'modelines' determines how many lines are tried (default is 5). Note
774that this is different from the Vi versions that can execute any Ex command
775in a modeline (a major security problem). |trojan-horse|
776
777If the 'insertmode' option is set (e.g. in .exrc), Vim starts in insert mode.
778And it comes back there, when pressing <Esc>.
779
780Undo information is kept in memory. Available memory limits the number and
781size of change that can be undone. This may be a problem with MS-DOS, is
782hardly a problem on the Amiga and almost never with Unix and Win32.
783
784If the 'backup' or 'writebackup' option is set: Before a file is overwritten,
785a backup file (.bak) is made. If the "backup" option is set it is left
786behind.
787
788Vim creates a file ending in ".swp" to store parts of the file that have been
789changed or that do not fit in memory. This file can be used to recover from
790an aborted editing session with "vim -r file". Using the swap file can be
791switched off by setting the 'updatecount' option to 0 or starting Vim with
792the "-n" option. Use the 'directory' option for placing the .swp file
793somewhere else.
794
795Vim is able to work correctly on filesystems with 8.3 file names, also when
796using messydos or crossdos filesystems on the Amiga, or any 8.3 mounted
797filesystem under Unix. See |'shortname'|.
798
799Error messages are shown at least one second (Vi overwrites error messages).
800
801If Vim gives the |hit-enter| prompt, you can hit any key. Characters other
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200802than <CR>, <NL> and <Space> are interpreted as the (start of) a command.
803{Vi: only ":" commands are interpreted}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000804
805The contents of the numbered and unnamed registers is remembered when
806changing files.
807
808The "No lines in buffer" message is a normal message instead of an error
809message, since that may cause a mapping to be aborted.
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200810{Vi: error messages may be overwritten with other messages before you have a
811chance to read them}
Bram Moolenaar071d4272004-06-13 20:20:40 +0000812
813The AUX: device of the Amiga is supported.
814
815==============================================================================
Bram Moolenaar6c60f472019-04-28 16:00:35 +02008166. Supported Vi features *vi-features*
817
818Vim supports nearly all Vi commands and mostly in the same way. That is when
819the 'compatible' option is set and 'cpoptions' contains all flags. What the
820effect is of resetting 'compatible' and removing flags from 'cpoptions' can be
821found at the help for the specific command.
822
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200823The help files used to mark features that are in Vim but not in Vi with {not
824in Vi}. However, since these remarks cluttered the help files we now do it
825the other way around: Below is listed what Vi already supported. Anything
826else has been added by Vim.
827
Bram Moolenaar6c60f472019-04-28 16:00:35 +0200828
829The following Ex commands are supported by Vi: ~
830
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200831`:abbreviate` enter abbreviation
832`:append` append text
833`:args` print the argument list
834`:cd` change directory; Vi: no "cd -"
835`:change` replace a line or series of lines
836`:chdir` change directory
837`:copy` copy lines
838`:delete` delete lines
839`:edit` edit a file
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200840`:exit` same as `:xit`
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200841`:file` show or set the current file name; Vi: without the column number
842`:global` execute commands for matching lines
843`:insert` insert text
844`:join` join lines; Vi: not :join!
845`:k` set a mark
846`:list` print lines
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200847`:map` show or enter a mapping
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200848`:mark` set a mark
849`:move` move lines
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200850`:Next` go to previous file in the argument list {Vi: no count}
851`:next` go to next file in the argument list {Vi: no count}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200852`:number` print lines with line number
853`:open` start open mode (not implemented in Vim)
854`:pop` jump to older entry in tag stack (only in some versions)
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200855`:preserve` write all text to swap file {Vi: might also exit}
856`:previous` same as `:Next` {Vi: only in some versions}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200857`:print` print lines
858`:put` insert contents of register in the text
859`:quit` quit Vi
860`:read` read file into the text
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200861`:recover` recover a file from a swap file {Vi: recovers in another way
862 and sends mail if there is something to recover}
863`:rewind` go to the first file in the argument list; no ++opt
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200864`:set` set option; but not `:set inv{option}`, `:set option&`,
865 `:set all&`, `:set option+=value`, `:set option^=value`
866 `:set option-=value` `:set option<`
867`:shell` escape to a shell
Bram Moolenaar68e65602019-05-26 21:33:31 +0200868`:source` read Vi or Ex commands from a file
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200869`:stop` suspend the editor or escape to a shell
870`:substitute` find and replace text; Vi: no '&', 'i', 's', 'r' or 'I' flag,
871 confirm prompt only supports 'y' and 'n', no highlighting
872`:suspend` same as ":stop"
873`:t` same as ":copy"
874`:tag` jump to tag
875`:unabbreviate` remove abbreviation
876`:undo` undo last change {Vi: only one level}
877`:unmap` remove mapping
878`:vglobal` execute commands for not matching lines
879`:version` print version number and other info
880`:visual` same as ":edit", but turns off "Ex" mode
881`:wq` write to a file and quit Vi
882`:write` write to a file
883`:xit` write if buffer changed and quit Vi
884`:yank` yank lines into a register
885`:z` print some lines {not in all versions of Vi}
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200886`:!` filter lines or execute an external command
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200887`:"` comment
888`:#` same as ":number"
889`:*` execute contents of a register
890`:&` repeat last ":substitute"
891`:<` shift lines one 'shiftwidth' left
892`:=` print the cursor line number
893`:>` shift lines one 'shiftwidth' right
894`:@` execute contents of a register; but not `:@`; `:@@` only in
895 some versions
Bram Moolenaar6c60f472019-04-28 16:00:35 +0200896
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200897Common for these commands is that Vi doesn't support the ++opt argument on
898`:edit` and other commands that open a file.
899
Bram Moolenaar6c60f472019-04-28 16:00:35 +0200900
901The following Normal mode commands are supported by Vi: ~
902
Bram Moolenaar68e65602019-05-26 21:33:31 +0200903note: See the beginning of |normal-index| for the meaning of WORD, N, Nmove
904and etc in the description text.
905
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200906|CTRL-B| scroll N screens Backwards
907|CTRL-C| interrupt current (search) command
908|CTRL-D| scroll Down N lines (default: half a screen); Vim scrolls
909 'scroll' screen lines, Vi scrolls file lines; makes a
910 difference when lines wrap
911|CTRL-E| scroll N lines upwards (N lines Extra)
912|CTRL-F| scroll N screens Forward
913|CTRL-G| display current file name and position
914|<BS>| same as "h"
915|CTRL-H| same as "h"
916|<NL>| same as "j"
917|CTRL-J| same as "j"
918|CTRL-L| redraw screen
919|<CR>| cursor to the first CHAR N lines lower
920|CTRL-M| same as <CR>
921|CTRL-N| same as "j"
922|CTRL-P| same as "k"
923|CTRL-R| in some Vi versions: same as CTRL-L
924|CTRL-T| jump to N older Tag in tag list
Bram Moolenaar68e65602019-05-26 21:33:31 +0200925|CTRL-U| N lines Upwards (default: half a screen) {Vi used file lines
926 while Vim scrolls 'scroll' screen lines; makes a difference
927 when lines wrap}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200928|CTRL-Y| scroll N lines downwards
929|CTRL-Z| suspend program (or start new shell)
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200930|CTRL-]| :ta to ident under cursor {Vi: identifier after the cursor}
931|CTRL-^| edit alternate file {Vi: no count}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200932|<Space>| same as "l"
933|!| filter Nmove text through the {filter} command
934|!!| filter N lines through the {filter} command
935" use register {a-zA-Z0-9.%#:-"} for next delete, yank or put
936 (uppercase to append) ({.%#:} only work with put)
937|$| cursor to the end of Nth next line
938|%| find the next (curly/square) bracket on this line and go to
939 its match, or go to matching comment bracket, or go to
940 matching preprocessor directive (Vi: no count supported)
941|&| repeat last :s
942|'| jump to mark (Vi: only lowercase marks)
943|(| cursor N sentences backward
944|)| cursor N sentences forward
945|+| same as <CR>
946|,| repeat latest f, t, F or T in opposite direction N times
947|-| cursor to the first CHAR N lines higher
948|.| repeat last change with count replaced with N
949|/| search forward for the Nth occurrence of {pattern}
950|0| cursor to the first char of the line
951|:| start entering an Ex command
952|;| repeat latest f, t, F or T N times
953|<| shift Nmove lines one 'shiftwidth' leftwards
954|<<| shift N lines one 'shiftwidth' leftwards
955|=| filter Nmove lines through "indent"
956|==| filter N lines through "indent"
957|>| shift Nmove lines one 'shiftwidth' rightwards
958|>>| shift N lines one 'shiftwidth' rightwards
959|?| search backward for the Nth previous occurrence of {pattern}
960|@| execute the contents of register {a-z} N times
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200961 {Vi: only named registers}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200962|@@| repeat the previous @{a-z} N times
963|A| append text after the end of the line N times
964|B| cursor N WORDS backward
965|C| change from the cursor position to the end of the line
966|D| delete the characters under the cursor until the end of the
967 line and N-1 more lines [into register x]; synonym for "d$"
968|E| cursor forward to the end of WORD N
969|F| cursor to the Nth occurrence of {char} to the left
970|G| cursor to line N, default last line
971|H| cursor to line N from top of screen
972|I| insert text before the first CHAR on the line N times
973|J| Join N lines; default is 2
974|L| cursor to line N from bottom of screen
975|M| cursor to middle line of screen
976|N| repeat the latest '/' or '?' N times in opposite direction
977|O| begin a new line above the cursor and insert text, repeat N
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200978 times {Vi: blank [count] screen lines}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200979|P| put the text [from register x] before the cursor N times
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200980 {Vi: no count}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200981|Q| switch to "Ex" mode
982|R| enter replace mode: overtype existing characters, repeat the
983 entered text N-1 times
984|S| delete N lines [into register x] and start insert; synonym for
985 "cc".
986|T| cursor till after Nth occurrence of {char} to the left
987|U| undo all latest changes on one line
Bram Moolenaara6c27c42019-05-09 19:16:22 +0200988 {Vi: while not moved off of the last modified line}
Bram Moolenaar25c9c682019-05-05 18:13:34 +0200989|W| cursor N WORDS forward
990|X| delete N characters before the cursor [into register x]
991|Y| yank N lines [into register x]; synonym for "yy"
992|ZZ| store current file if modified, and exit
993|[[| cursor N sections backward
994|]]| cursor N sections forward
995|^| cursor to the first CHAR of the line
996|_| cursor to the first CHAR N - 1 lines lower
997|`| cursor to the mark {a-zA-Z0-9}
998|a| append text after the cursor N times
999|b| cursor N words backward
1000|c| delete Nmove text [into register x] and start insert
1001|cc| delete N lines [into register x] and start insert
1002|d| delete Nmove text [into register x]
1003|dd| delete N lines [into register x]
1004|e| cursor forward to the end of word N
1005|f| cursor to Nth occurrence of {char} to the right
1006|h| cursor N chars to the left
1007|i| insert text before the cursor N times
1008|j| cursor N lines downward
1009|k| cursor N lines upward
1010|l| cursor N chars to the right
1011|m| set mark {A-Za-z} at cursor position
1012|n| repeat the latest '/' or '?' N times
1013|o| begin a new line below the cursor and insert text
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001014 {Vi: blank [count] screen lines}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001015|p| put the text [from register x] after the cursor N times
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001016 {Vi: no count}
1017|r| replace N chars with {char} {Vi: CTRL-V <CR> still replaces
1018 with a line break, cannot replace something with a <CR>}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001019|s| (substitute) delete N characters [into register x] and start
1020 insert
1021|t| cursor till before Nth occurrence of {char} to the right
1022|u| undo changes {Vi: only one level}
1023|w| cursor N words forward
1024|x| delete N characters under and after the cursor [into register
1025 x]
1026|y| yank Nmove text [into register x]
1027|yy| yank N lines [into register x]
1028|z<CR>| current line to the top
1029|z-| current line to the bottom
1030|z+| cursor on line N
1031|z^| cursor on line N
1032|{| cursor N paragraphs backward
1033| cursor to column N
1034|}| cursor N paragraphs forward
1035|~| switch case of N characters under the cursor; Vim: depends on
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001036 'tildeop' {Vi: no count, no 'tildeop'}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001037|<Del>| same as "x"
1038
1039
1040The following commands are supported in Insert mode by Vi: ~
1041
1042CTRL-@ insert previously inserted text and stop insert
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001043 {Vi: only when typed as first char, only up to 128 chars}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001044CTRL-C quit insert mode, without checking for abbreviation, unless
1045 'insertmode' set.
1046CTRL-D delete one shiftwidth of indent in the current line
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001047 {Vi: CTRL-D works only when used after autoindent}
1048<BS> delete character before the cursor {Vi: does not delete
1049 autoindents, does not cross lines, does not delete past start
1050 position of insert}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001051CTRL-H same as <BS>
1052<Tab> insert a <Tab> character
1053CTRL-I same as <Tab>
1054<NL> same as <CR>
1055CTRL-J same as <CR>
1056<CR> begin new line
1057CTRL-M same as <CR>
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001058CTRL-T insert one shiftwidth of indent in current line {Vi: only when
1059 in indent}
1060CTRL-V {char} insert next non-digit literally {Vi: no decimal byte entry}
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001061CTRL-W delete word before the cursor
Bram Moolenaar68e65602019-05-26 21:33:31 +02001062CTRL-Z when 'insertmode' set: suspend Vi
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001063<Esc> end insert mode (unless 'insertmode' set)
1064CTRL-[ same as <Esc>
10650 CTRL-D delete all indent in the current line
1066^ CTRL-D delete all indent in the current line, restore it in the next
1067 line
1068<Del> delete character under the cursor
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001069
1070
1071The following options are supported by Vi: ~
1072
1073'autoindent' 'ai' take indent for new line from previous line
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001074 {Vi does this slightly differently: After the
1075 indent is deleted when typing <Esc> or <CR>, the
1076 cursor position when moving up or down is after
1077 the deleted indent; Vi puts the cursor somewhere
1078 in the deleted indent}.
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001079'autowrite' 'aw' automatically write file if changed
1080'directory' 'dir' list of directory names for the swap file
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001081 {Vi: directory to put temp file in, defaults to
1082 "/tmp"}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001083'edcompatible' 'ed' toggle flags of ":substitute" command
1084'errorbells' 'eb' ring the bell for error messages
1085'ignorecase' 'ic' ignore case in search patterns
1086'lines' number of lines in the display
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001087'lisp' automatic indenting for Lisp {Vi: Does it a little
1088 bit differently}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001089'list' show <Tab> and <EOL>
1090'magic' changes special characters in search patterns
1091'modeline' 'ml' recognize 'modelines' at start or end of file
1092 {called modelines in some Vi versions}
1093'number' 'nu' print the line number in front of each line
1094'paragraphs' 'para' nroff macros that separate paragraphs
1095'prompt' 'prompt' enable prompt in Ex mode
1096'readonly' 'ro' disallow writing the buffer {Vim sets 'readonly'
1097 when editing a file with `:view`}
1098'remap' allow mappings to work recursively
1099'report' threshold for reporting nr. of lines changed
1100'scroll' 'scr' lines to scroll with CTRL-U and CTRL-D
1101'sections' 'sect' nroff macros that separate sections
1102'shell' 'sh' name of shell to use for external commands
1103'shiftwidth' 'sw' number of spaces to use for (auto)indent step
1104'showmatch' 'sm' briefly jump to matching bracket if insert one
1105'showmode' 'smd' message on status line to show current mode
1106'tabstop' 'ts' number of spaces that <Tab> in file uses
1107'taglength' 'tl' number of significant characters for a tag
1108'tags' 'tag' list of file names used by the tag command
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001109 {Vi: default is "tags /usr/lib/tags"}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001110'tagstack' 'tgst' push tags onto the tag stack {not in all versions
1111 of Vi}
1112'term' name of the terminal
1113'terse' shorten some messages
1114'timeout' 'to' time out on mappings and key codes
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001115'timeoutlen' 'tm' time for 'timeout' {only in some Vi versions}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001116'ttytype' 'tty' alias for 'term'
1117'verbose' 'vbs' give informative messages {only in some Vi
1118 versions as a boolean option}
1119'warn' warn for shell command when buffer was changed
1120'window' 'wi' nr of lines to scroll for CTRL-F and CTRL-B
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001121 {Vi also uses the option to specify the number of
1122 displayed lines}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001123'wrapmargin' 'wm' chars from the right where wrapping starts
Bram Moolenaara6c27c42019-05-09 19:16:22 +02001124 {Vi: works differently and less usefully}
Bram Moolenaar6c60f472019-04-28 16:00:35 +02001125'wrapscan' 'ws' searches wrap around the end of the file
1126'writeany' 'wa' write to file with no need for "!" override
1127
1128Also see |missing-options|.
1129
1130==============================================================================
11317. Command-line arguments *cmdline-arguments*
Bram Moolenaar071d4272004-06-13 20:20:40 +00001132
1133Different versions of Vi have different command-line arguments. This can be
1134confusing. To help you, this section gives an overview of the differences.
1135
1136Five variants of Vi will be considered here:
1137 Elvis Elvis version 2.1b
1138 Nvi Nvi version 1.79
1139 Posix Posix 1003.2
1140 Vi Vi version 3.7 (for Sun 4.1.x)
1141 Vile Vile version 7.4 (incomplete)
1142 Vim Vim version 5.2
1143
1144Only Vim is able to accept options in between and after the file names.
1145
1146+{command} Elvis, Nvi, Posix, Vi, Vim: Same as "-c {command}".
1147
1148- Nvi, Posix, Vi: Run Ex in batch mode.
1149 Vim: Read file from stdin (use -s for batch mode).
1150
1151-- Vim: End of options, only file names are following.
1152
1153--cmd {command} Vim: execute {command} before sourcing vimrc files.
1154
1155--echo-wid Vim: GTK+ echoes the Window ID on stdout
1156
1157--help Vim: show help message and exit.
1158
1159--literal Vim: take file names literally, don't expand wildcards.
1160
1161--nofork Vim: same as |-f|
1162
1163--noplugin[s] Vim: Skip loading plugins.
1164
1165--remote Vim: edit the files in another Vim server
1166
1167--remote-expr {expr} Vim: evaluate {expr} in another Vim server
1168
1169--remote-send {keys} Vim: send {keys} to a Vim server and exit
1170
1171--remote-silent {file} Vim: edit the files in another Vim server if possible
1172
1173--remote-wait Vim: edit the files in another Vim server and wait for it
1174
1175--remote-wait-silent Vim: like --remote-wait, no complaints if not possible
1176
1177--role {role} Vim: GTK+ 2: set role of main window
1178
1179--serverlist Vim: Output a list of Vim servers and exit
1180
1181--servername {name} Vim: Specify Vim server name
1182
1183--socketid {id} Vim: GTK window socket to run Vim in
1184
Bram Moolenaar78e17622007-08-30 10:26:19 +00001185--windowid {id} Vim: Win32 window ID to run Vim in
1186
Bram Moolenaar071d4272004-06-13 20:20:40 +00001187--version Vim: show version message and exit.
1188
1189-? Vile: print usage summary and exit.
1190
1191-a Elvis: Load all specified file names into a window (use -o for
1192 Vim).
1193
1194-A Vim: Start in Arabic mode (when compiled with Arabic).
1195
1196-b {blksize} Elvis: Use {blksize} blocksize for the session file.
1197-b Vim: set 'binary' mode.
1198
1199-C Vim: Compatible mode.
1200
1201-c {command} Elvis, Nvi, Posix, Vim: run {command} as an Ex command after
1202 loading the edit buffer.
1203 Vim: allow up to 10 "-c" arguments
1204
1205-d {device} Vim: Use {device} for I/O (Amiga only). {only when compiled
1206 without the |+diff| feature}
1207-d Vim: start with 'diff' set. |vimdiff|
1208
1209-dev {device} Vim: Use {device} for I/O (Amiga only).
1210
1211-D Vim: debug mode.
1212
1213-e Elvis, Nvi, Vim: Start in Ex mode, as if the executable is
1214 called "ex".
1215
1216-E Vim: Start in improved Ex mode |gQ|, like "exim".
1217
1218-f Vim: Run GUI in foreground (Amiga: don't open new window).
1219-f {session} Elvis: Use {session} as the session file.
1220
1221-F Vim: Start in Farsi mode (when compiled with Farsi).
1222 Nvi: Fast start, don't read the entire file when editing
1223 starts.
1224
1225-G {gui} Elvis: Use the {gui} as user interface.
1226
1227-g Vim: Start GUI.
1228-g N Vile: start editing at line N
1229
1230-h Vim: Give help message.
1231 Vile: edit the help file
1232
1233-H Vim: start Hebrew mode (when compiled with it).
1234
1235-i Elvis: Start each window in Insert mode.
1236-i {viminfo} Vim: Use {viminfo} for viminfo file.
1237
Bram Moolenaar25c9c682019-05-05 18:13:34 +02001238-L Vim: Same as "-r" {only in some versions of Vi: "List
1239 recoverable edit sessions"}.
Bram Moolenaar071d4272004-06-13 20:20:40 +00001240
1241-l Nvi, Vi, Vim: Set 'lisp' and 'showmatch' options.
1242
1243-m Vim: Modifications not allowed to be written, resets 'write'
1244 option.
1245
1246-M Vim: Modifications not allowed, resets 'modifiable' and the
1247 'write' option.
1248
1249-N Vim: No-compatible mode.
1250
1251-n Vim: No swap file used.
1252
1253-nb[args] Vim: open a NetBeans interface connection
1254
1255-O[N] Vim: Like -o, but use vertically split windows.
1256
1257-o[N] Vim: Open [N] windows, or one for each file.
1258
Bram Moolenaar18144c82006-04-12 21:52:12 +00001259-p[N] Vim: Open [N] tab pages, or one for each file.
1260
Bram Moolenaar071d4272004-06-13 20:20:40 +00001261-P {parent-title} Win32 Vim: open Vim inside a parent application window
1262
1263-q {name} Vim: Use {name} for quickfix error file.
1264-q{name} Vim: Idem.
1265
1266-R Elvis, Nvi, Posix, Vile, Vim: Set the 'readonly' option.
1267
1268-r Elvis, Nvi, Posix, Vi, Vim: Recovery mode.
1269
1270-S Nvi: Set 'secure' option.
1271-S {script} Vim: source script after starting up.
1272
1273-s Nvi, Posix, Vim: Same as "-" (silent mode), when in Ex mode.
1274 Elvis: Sets the 'safer' option.
1275-s {scriptin} Vim: Read from script file {scriptin}; only when not in Ex
1276 mode.
1277-s {pattern} Vile: search for {pattern}
1278
1279-t {tag} Elvis, Nvi, Posix, Vi, Vim: Edit the file containing {tag}.
1280-t{tag} Vim: Idem.
1281
1282-T {term} Vim: Set terminal name to {term}.
1283
1284-u {vimrc} Vim: Read initializations from {vimrc} file.
1285
1286-U {gvimrc} Vim: Read GUI initializations from {gvimrc} file.
1287
1288-v Nvi, Posix, Vi, Vim: Begin in Normal mode (visual mode, in Vi
1289 terms).
1290 Vile: View mode, no changes possible.
1291
1292-V Elvis, Vim: Verbose mode.
1293-V{nr} Vim: Verbose mode with specified level.
1294
1295-w {size} Elvis, Posix, Nvi, Vi, Vim: Set value of 'window' to {size}.
1296-w{size} Nvi, Vi: Same as "-w {size}".
1297-w {name} Vim: Write to script file {name} (must start with non-digit).
1298
1299-W {name} Vim: Append to script file {name}.
1300
1301-x Vi, Vim: Ask for encryption key. See |encryption|.
1302
1303-X Vim: Don't connect to the X server.
1304
1305-y Vim: Start in easy mode, like |evim|.
1306
1307-Z Vim: restricted mode
1308
1309@{cmdfile} Vile: use {cmdfile} as startup file.
1310
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001311==============================================================================
Bram Moolenaar6c60f472019-04-28 16:00:35 +020013128. POSIX compliance *posix* *posix-compliance*
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001313
Bram Moolenaardd2a3cd2007-05-05 17:10:09 +00001314In 2005 the POSIX test suite was run to check the compatibility of Vim. Most
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001315of the test was executed properly. There are the few things where Vim
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +00001316is not POSIX compliant, even when run in Vi compatibility mode.
Bram Moolenaar38a55632016-02-15 22:07:32 +01001317 *$VIM_POSIX*
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001318Set the $VIM_POSIX environment variable to have 'cpoptions' include the POSIX
1319flags when Vim starts up. This makes Vim run as POSIX as it can. That's
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +00001320a bit different from being Vi compatible.
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001321
Bram Moolenaar574ee7b2019-11-13 23:04:29 +01001322You can find the Posix specification for Vi here:
1323https://pubs.opengroup.org/onlinepubs/9699919799/utilities/vi.html
1324And the related Ex specification:
1325https://pubs.opengroup.org/onlinepubs/9699919799/utilities/ex.html
1326
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001327This is where Vim does not behave as POSIX specifies and why:
1328
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001329 *posix-screen-size*
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001330 The $COLUMNS and $LINES environment variables are ignored by Vim if
1331 the size can be obtained from the terminal in a more reliable way.
1332 Add the '|' flag to 'cpoptions' to have $COLUMNS and $LINES overrule
1333 sizes obtained in another way.
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001334
Bram Moolenaar4399ef42005-02-12 14:29:27 +00001335 The "{" and "}" commands don't stop at a "{" in the original Vi, but
1336 POSIX specifies it does. Add the '{' flag to 'cpoptions' if you want
1337 it the POSIX way.
1338
1339 The "D", "o" and "O" commands accept a count. Also when repeated.
1340 Add the '#' flag to 'cpoptions' if you want to ignore the count.
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001341
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +00001342 The ":cd" command fails if the current buffer is modified when the '.'
1343 flag is present in 'cpoptions'.
1344
1345 There is no ATTENTION message, the "A" flag is added to 'shortmess'.
1346
1347These are remarks about running the POSIX test suite:
1348- vi test 33 sometimes fails for unknown reasons
1349- vi test 250 fails; behavior will be changed in a new revision
1350 http://www.opengroup.org/austin/mailarchives/ag-review/msg01710.html
Bram Moolenaar483c5d82010-10-20 18:45:33 +02001351 (link no longer works, perhaps it's now:
1352 https://www.opengroup.org/sophocles/show_mail.tpl?CALLER=show_archive.tpl&source=L&listname=austin-review-l&id=1711)
Bram Moolenaar6bdcfc02005-02-22 08:28:13 +00001353- vi test 310 fails; exit code non-zero when any error occurred?
1354- ex test 24 fails because test is wrong. Changed between SUSv2 and SUSv3.
1355- ex tests 47, 48, 49, 72, 73 fail because .exrc file isn't read in silent
1356 mode and $EXINIT isn't used.
1357- ex tests 76, 78 fail because echo is used instead of printf. (fixed)
1358 Also: problem with \s not changed to space.
1359- ex test 355 fails because 'window' isn't used for "30z".
1360- ex test 368 fails because shell command isn't echoed in silent mode.
1361- ex test 394 fails because "=" command output isn't visible in silent mode.
1362- ex test 411 fails because test file is wrong, contains stray ':'.
1363- ex test 475 and 476 fail because reprint output isn't visible in silent mode.
1364- ex test 480 and 481 fail because the tags file has spaces instead of a tab.
1365- ex test 502 fails because .exrc isn't read in silent mode.
1366- ex test 509 fails because .exrc isn't read in silent mode. and exit code is
1367 1 instead of 2.
1368- ex test 534 fails because .exrc isn't read in silent mode.
1369
Bram Moolenaarf97ca8f2005-02-07 21:49:25 +00001370
Bram Moolenaard473c8c2018-08-11 18:00:22 +02001371 vim:tw=78:ts=8:noet:ft=help:norl: