diff options
author | James McCoy <jamessan@jamessan.com> | 2017-01-06 09:47:30 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-06 09:47:30 -0500 |
commit | f82f27ccec4e42ba28a9924738e3611d8ca6c626 (patch) | |
tree | 845b0fb0d0e2934dd845d6f62a551c005405068f /runtime | |
parent | 23b39ebb24d6468d6dda76ffbb88f1fd3b99501c (diff) | |
parent | 6c69bc978848df8bb268b74b0e5a01eeb87a32dd (diff) | |
download | rneovim-f82f27ccec4e42ba28a9924738e3611d8ca6c626.tar.gz rneovim-f82f27ccec4e42ba28a9924738e3611d8ca6c626.tar.bz2 rneovim-f82f27ccec4e42ba28a9924738e3611d8ca6c626.zip |
Merge pull request #5892 from lonerover/vim-7.4.2103
vim-patch: 7.4.2103
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/autocmd.txt | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt index 4f23aee83d..65e091edf5 100644 --- a/runtime/doc/autocmd.txt +++ b/runtime/doc/autocmd.txt @@ -49,9 +49,6 @@ effects. Be careful not to destroy your text. ============================================================================== 2. Defining autocommands *autocmd-define* -Note: The ":autocmd" command cannot be followed by another command, since any -'|' is considered part of the command. - *:au* *:autocmd* :au[tocmd] [group] {event} {pat} [nested] {cmd} Add {cmd} to the list of commands that Vim will @@ -64,6 +61,12 @@ Note: The ":autocmd" command cannot be followed by another command, since any The special pattern <buffer> or <buffer=N> defines a buffer-local autocommand. See |autocmd-buflocal|. +Note: The ":autocmd" command can only be followed by another command when the +'|' appears before {cmd}. This works: > + :augroup mine | au! BufRead | augroup END +But this sees "augroup" as part of the defined command: > + :augroup mine | au BufRead * set tw=70 | augroup END + Note that special characters (e.g., "%", "<cword>") in the ":autocmd" arguments are not expanded when the autocommand is defined. These will be expanded when the Event is recognized, and the {cmd} is executed. The only |