aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc')
-rw-r--r--runtime/doc/autocmd.txt17
-rw-r--r--runtime/doc/cmdline.txt5
-rw-r--r--runtime/doc/editing.txt3
-rw-r--r--runtime/doc/eval.txt4
-rw-r--r--runtime/doc/index.txt4
-rw-r--r--runtime/doc/options.txt2
-rw-r--r--runtime/doc/syntax.txt9
7 files changed, 31 insertions, 13 deletions
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt
index b27a1a8763..f783438fc9 100644
--- a/runtime/doc/autocmd.txt
+++ b/runtime/doc/autocmd.txt
@@ -76,11 +76,15 @@ exception is that "<sfile>" is expanded when the autocmd is defined. Example:
Here Vim expands <sfile> to the name of the file containing this line.
-When your vimrc file is sourced twice, the autocommands will appear twice.
-To avoid this, put this command in your vimrc file, before defining
-autocommands: >
+`:autocmd` adds to the list of autocommands regardless of whether they are
+already present. When your .vimrc file is sourced twice, the autocommands
+will appear twice. To avoid this, define your autocommands in a group, so
+that you can easily clear them: >
- :autocmd! " Remove ALL autocommands for the current group.
+ augroup vimrc
+ autocmd! " Remove all vimrc autocommands
+ au BufNewFile,BufRead *.html so <sfile>:h/html.vim
+ augroup END
If you don't want to remove all autocommands, you can instead use a variable
to ensure that Vim includes the autocommands only once: >
@@ -127,8 +131,13 @@ prompt. When one command outputs two messages this can happen anyway.
:au[tocmd]! [group] {event}
Remove ALL autocommands for {event}.
+ Warning: You should not do this without a group for
+ |BufRead| and other common events, it can break
+ plugins, syntax highlighting, etc.
:au[tocmd]! [group] Remove ALL autocommands.
+ Warning: You should normally not do this without a
+ group, it breaks plugins, syntax highlighting, etc.
When the [group] argument is not given, Vim uses the current group (as defined
with ":augroup"); otherwise, Vim uses the group defined with [group].
diff --git a/runtime/doc/cmdline.txt b/runtime/doc/cmdline.txt
index 7277e1d22e..3e041c3b62 100644
--- a/runtime/doc/cmdline.txt
+++ b/runtime/doc/cmdline.txt
@@ -219,9 +219,10 @@ CTRL-Y When there is a modeless selection, copy the selection into
the clipboard. |modeless-selection|
If there is no selection CTRL-Y is inserted as a character.
-CTRL-J *c_CTRL-J* *c_<NL>* *c_<CR>* *c_CR*
+CTRL-M or CTRL-J *c_CTRL-M* *c_CTRL-J* *c_<NL>* *c_<CR>* *c_CR*
<CR> or <NL> start entered command
- *c_<Esc>* *c_Esc*
+
+CTRL-[ *c_CTRL-[* *c_<Esc>* *c_Esc*
<Esc> When typed and 'x' not present in 'cpoptions', quit
Command-line mode without executing. In macros or when 'x'
present in 'cpoptions', start entered command.
diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt
index 57458b7b81..7007a89611 100644
--- a/runtime/doc/editing.txt
+++ b/runtime/doc/editing.txt
@@ -160,7 +160,8 @@ start editing another file, Vim will refuse this. In order to overrule this
protection, add a '!' to the command. The changes will then be lost. For
example: ":q" will not work if the buffer was changed, but ":q!" will. To see
whether the buffer was changed use the "CTRL-G" command. The message includes
-the string "[Modified]" if the buffer has been changed.
+the string "[Modified]" if the buffer has been changed, or "+" if the 'm' flag
+is in 'shortmess'.
If you want to automatically save the changes without asking, switch on the
'autowriteall' option. 'autowrite' is the associated Vi-compatible option
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index 19c1f0c23d..2d6c6ee3a0 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -1241,7 +1241,7 @@ Examples for using a lambda expression with |sort()|, |map()| and |filter()|: >
:echo sort([3,7,2,1,4], {a, b -> a - b})
< [1, 2, 3, 4, 7]
-The lambda expression is also useful for Channel, Job and timer: >
+The lambda expression is also useful for jobs and timers: >
:let timer = timer_start(500,
\ {-> execute("echo 'Handler called'", "")},
\ {'repeat': 3})
@@ -3518,7 +3518,7 @@ filter({expr1}, {expr2}) *filter()*
call filter(myList, {idx, val -> idx * val <= 42})
< If you do not use "val" you can leave it out: >
call filter(myList, {idx -> idx % 2 == 1})
-
+<
The operation is done in-place. If you want a |List| or
|Dictionary| to remain unmodified make a copy first: >
:let l = filter(copy(mylist), 'v:val =~ "KEEP"')
diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt
index 7267a45d41..16e9d4a64d 100644
--- a/runtime/doc/index.txt
+++ b/runtime/doc/index.txt
@@ -1000,7 +1000,7 @@ tag command action in Command-line editing mode ~
|c_CTRL-L| CTRL-L do completion on the pattern in front of the
cursor and insert the longest common part
|c_<CR>| <CR> execute entered command
-|c_<CR>| CTRL-M same as <CR>
+|c_CTRL-M| CTRL-M same as <CR>
|c_CTRL-N| CTRL-N after using 'wildchar' with multiple matches:
go to next match, otherwise: same as <Down>
CTRL-O not used
@@ -1024,7 +1024,7 @@ tag command action in Command-line editing mode ~
CTRL-Y copy (yank) modeless selection
CTRL-Z not used (reserved for suspend)
|c_<Esc>| <Esc> abandon command-line without executing it
-|c_<Esc>| CTRL-[ same as <Esc>
+|c_CTRL-[| CTRL-[ same as <Esc>
|c_CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode, abandon command-line
|c_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode',
abandon command-line
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt
index 7ca6612225..b0b47cc243 100644
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -10,7 +10,7 @@ Options *options*
2. Automatically setting options |auto-setting|
3. Options summary |option-summary|
-For an overview of options see help.txt |option-list|.
+For an overview of options see quickref.txt |option-list|.
Vim has a number of internal variables and switches which can be set to
achieve special effects. These options come in three forms:
diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt
index e3da736489..1ee35e19dd 100644
--- a/runtime/doc/syntax.txt
+++ b/runtime/doc/syntax.txt
@@ -3555,7 +3555,11 @@ DEFINING KEYWORDS *:syn-keyword*
DEFINING MATCHES *:syn-match*
-:sy[ntax] match {group-name} [{options}] [excludenl] {pattern} [{options}]
+:sy[ntax] match {group-name} [{options}]
+ [excludenl]
+ [keepend]
+ {pattern}
+ [{options}]
This defines one match.
@@ -3564,6 +3568,9 @@ DEFINING MATCHES *:syn-match*
[excludenl] Don't make a pattern with the end-of-line "$"
extend a containing match or region. Must be
given before the pattern. |:syn-excludenl|
+ keepend Don't allow contained matches to go past a
+ match with the end pattern. See
+ |:syn-keepend|.
{pattern} The search pattern that defines the match.
See |:syn-pattern| below.
Note that the pattern may match more than one