From e902a172ef1a58e93eeae0919bddb3578a2142a2 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 25 Apr 2016 23:07:51 -0400 Subject: vim-patch:7.4.1384 Problem: It is not easy to use a set of plugins and their dependencies. Solution: Add packages, ":loadopt", 'packpath'. https://github.com/vim/vim/commit/f6fee0e2d4341c0c2f5339c1268e5877fafd07cf --- runtime/doc/options.txt | 9 +++++- runtime/doc/repeat.txt | 76 ++++++++++++++++++++++++++++++++++++++++++++---- runtime/doc/starting.txt | 6 +++- 3 files changed, 84 insertions(+), 7 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 8c2b7786a7..99b9ca0eb1 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 7.4. Last change: 2016 Feb 20 +*options.txt* For Vim version 7.4. Last change: 2016 Feb 21 VIM REFERENCE MANUAL by Bram Moolenaar @@ -4499,6 +4499,13 @@ A jump table for the options with a short description can be found at |Q_op|. This option cannot be set from a |modeline| or in the |sandbox|, for security reasons. + *'packpath'* *'pp'* +'packpath' 'pp' string (default: see 'runtimepath') + {not in Vi} + {not available without the |+packages| feature} + Directories used to find packages. See |packages|. + + *'paragraphs'* *'para'* 'paragraphs' 'para' string (default "IPLPPPQPP TPHPLIPpLpItpplpipbp") global diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 5b382f95f2..c41d79214a 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 12 +*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 21 VIM REFERENCE MANUAL by Bram Moolenaar @@ -12,8 +12,9 @@ Chapter 26 of the user manual introduces repeating |usr_26.txt|. 2. Multiple repeats |multi-repeat| 3. Complex repeats |complex-repeat| 4. Using Vim scripts |using-scripts| -5. Debugging scripts |debug-scripts| -6. Profiling |profiling| +5. Using Vim packages |packages| +6. Debugging scripts |debug-scripts| +7. Profiling |profiling| ============================================================================== 1. Single repeats *single-repeat* @@ -203,6 +204,22 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. When 'verbose' is two or higher, there is a message about each searched file. + *:loadp* *:loadplugin* +:loadp[lugin] {name} Search for an optional plugin directory and source the + plugin files found. It is similar to: > + :runtime pack/*/opt/{name}/plugin/*.vim +< However, `:loadplugin` uses 'packpath' instead of + 'runtimepath'. And the directory found is added to + 'runtimepath'. + + Note that {name} is the directory name, not the name + of the .vim file. If the "{name}/plugin" directory + contains more than one file they are all sourced. + + Also see |load-plugin|. + + {not available without the |+packages| feature} + :scripte[ncoding] [encoding] *:scripte* *:scriptencoding* *E167* Specify the character encoding used in the script. The following lines will be converted from [encoding] @@ -373,7 +390,56 @@ Rationale: < Therefore the unusual leading backslash is used. ============================================================================== -5. Debugging scripts *debug-scripts* +5. Using Vim packages *packages* + +A Vim package is a directory that contains one or more plugins. The +advantages over normal plugins: +- A package can be downloaded as an archive and unpacked in its own directory. + That makes it easy to updated and/or remove. +- A package can be a git, mercurial, etc. respository. That makes it really + easy to update. +- A package can contain multiple plugins that depend on each other. +- A package can contain plugins that are automatically loaded on startup and + ones that are only loaded when needed with `:loadplugin`. + +Let's assume your Vim files are in the "~/.local/share/nvim/site" directory +and you want to add a package from a zip archive "/tmp/mypack.zip": + % mkdir -p ~/.local/share/nvim/site/pack/my + % cd ~/.local/share/nvim/site/pack/my + % unzip /tmp/mypack.zip + +The directory name "my" is arbitrary, you can pick anything you like. + +You would now have these files under ~/.local/share/nvim/site: + pack/my/README.txt + pack/my/ever/always/plugin/always.vim + pack/my/ever/always/syntax/always.vim + pack/my/opt/mydebug/plugin/debugger.vim + +When Vim starts up it scans all directories in 'packpath' for plugins under the +"ever" directory and loads them. When found that directory is added to +'runtimepath'. + +In the example Vim will find "my/ever/always/plugin/always.vim" and adds +"~/.local/share/nvim/site/pack/my/ever/always" to 'runtimepath'. + +If the "always" plugin kicks in and sets the 'filetype' to "always", Vim will +find the syntax/always.vim file, because its directory is in 'runtimepath'. + + *load-plugin* +To load an optional plugin from a pack use the `:loadplugin` command: > + :loadplugin mydebug +This could be done inside always.vim, if some conditions are met. +Or you could add this command to your |.vimrc|. + +It is perfectly normal for a package to only have files in the "opt" +directory. You then need to load each plugin when you want to use it. + +Loading packages will not happen if loading plugins is disabled, see +|load-plugins|. + +============================================================================== +6. Debugging scripts *debug-scripts* Besides the obvious messages that you can add to your scripts to find out what they are doing, Vim offers a debug mode. This allows you to step through a @@ -597,7 +663,7 @@ OBSCURE user, don't use typeahead for debug commands. ============================================================================== -6. Profiling *profile* *profiling* +7. Profiling *profile* *profiling* Profiling means that Vim measures the time that is spent on executing functions and/or scripts. The |+profile| feature is required for this. diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index ad2649b765..0508c52540 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Feb 18 +*starting.txt* For Vim version 7.4. Last change: 2016 Feb 21 VIM REFERENCE MANUAL by Bram Moolenaar @@ -463,6 +463,10 @@ accordingly. Vim proceeds in this order: commands from the command line have not been executed yet. You can use "--cmd 'set noloadplugins'" |--cmd|. + Plugin packs are loaded. These are plugins, as above, but found in + 'packpath' directories. Every plugin directory found is added in + 'runtimepath'. See |packages|. + 7. Set 'shellpipe' and 'shellredir' The 'shellpipe' and 'shellredir' options are set according to the value of the 'shell' option, unless they have been set before. -- cgit From 28300a1293b17072c1c5f053a55aae2268454246 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Sun, 19 Jun 2016 23:59:39 -0400 Subject: vim-patch:f391327 Updated runtime files. https://github.com/vim/vim/commit/f391327adbbffb11180cf6038a92af1ed144e907 Ignore changes to * doc/todo.txt: Irrelevant for Neovim * doc/channel.txt: Channel docs * doc/tags, syntax/vim.vim: Generated at build time --- runtime/doc/eval.txt | 2 +- runtime/doc/help.txt | 2 +- runtime/doc/index.txt | 3 ++- runtime/doc/options.txt | 3 +-- runtime/doc/quickref.txt | 3 ++- runtime/doc/repeat.txt | 4 +--- runtime/doc/syntax.txt | 9 ++++++++- 7 files changed, 16 insertions(+), 10 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 3ebfe8da88..04aff0b3bf 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Feb 19 +*eval.txt* For Vim version 7.4. Last change: 2016 Feb 23 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/help.txt b/runtime/doc/help.txt index 342c475f9b..fd5b9a99ec 100644 --- a/runtime/doc/help.txt +++ b/runtime/doc/help.txt @@ -1,4 +1,4 @@ -*help.txt* For Vim version 7.4. Last change: 2016 Jan 10 +*help.txt* For Vim version 7.4. Last change: 2016 Feb 22 VIM - main help file k diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt index e75031ccef..a974aa3d08 100644 --- a/runtime/doc/index.txt +++ b/runtime/doc/index.txt @@ -1,4 +1,4 @@ -*index.txt* For Vim version 7.4. Last change: 2016 Jan 19 +*index.txt* For Vim version 7.4. Last change: 2016 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1317,6 +1317,7 @@ tag command action ~ |:lnfile| :lnf[ile] go to first location in next file |:lnoremap| :ln[oremap] like ":noremap!" but includes Lang-Arg mode |:loadkeymap| :loadk[eymap] load the following keymaps until EOF +|:loadplugin| :loadp[lugin] load a plugin from 'packpath' |:loadview| :lo[adview] load view for current window from a file |:lockmarks| :loc[kmarks] following command keeps marks where they are |:lockvar| :lockv[ar] lock variables diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 99b9ca0eb1..887cff0707 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 7.4. Last change: 2016 Feb 21 +*options.txt* For Vim version 7.4. Last change: 2016 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -4502,7 +4502,6 @@ A jump table for the options with a short description can be found at |Q_op|. *'packpath'* *'pp'* 'packpath' 'pp' string (default: see 'runtimepath') {not in Vi} - {not available without the |+packages| feature} Directories used to find packages. See |packages|. diff --git a/runtime/doc/quickref.txt b/runtime/doc/quickref.txt index 8e40628e25..b6ab33dd16 100644 --- a/runtime/doc/quickref.txt +++ b/runtime/doc/quickref.txt @@ -1,4 +1,4 @@ -*quickref.txt* For Vim version 7.4. Last change: 2015 Nov 10 +*quickref.txt* For Vim version 7.4. Last change: 2016 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -794,6 +794,7 @@ Short explanation of each option: *option-list* 'omnifunc' 'ofu' function for filetype-specific completion 'opendevice' 'odev' allow reading/writing devices on MS-Windows 'operatorfunc' 'opfunc' function to be called for |g@| operator +'packpath' 'pp' list of directories used for packages 'paragraphs' 'para' nroff macros that separate paragraphs 'paste' allow pasting text 'pastetoggle' 'pt' key code that causes 'paste' to toggle diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index c41d79214a..4db3580efa 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 21 +*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -218,8 +218,6 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. Also see |load-plugin|. - {not available without the |+packages| feature} - :scripte[ncoding] [encoding] *:scripte* *:scriptencoding* *E167* Specify the character encoding used in the script. The following lines will be converted from [encoding] diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 4e4ea39e7c..f7e9ece3d8 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 7.4. Last change: 2016 Jan 28 +*syntax.txt* For Vim version 7.4. Last change: 2016 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -3345,6 +3345,13 @@ Note that schemas are not actually limited to plain scalars, but this is the only difference between schemas defined in YAML specification and the only difference defined in the syntax file. + +ZSH *zsh.vim* *ft-zsh-syntax* + +The syntax script for zsh allows for syntax-based folding: > + + :let g:zsh_fold_enable = 1 + ============================================================================== 5. Defining a syntax *:syn-define* *E410* -- cgit From 8f2505e5942d5e6bdc5250b002b402b10709deb0 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 00:10:08 -0400 Subject: vim-patch:dae8d21 Updated runtime files https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576 Ignore changes to * doc/eval.txt: Channel related docs * doc/help.txt, doc/index.txt, doc/os_390.txt: Removal of obsolete features, which already happened in Neovim * doc/tags: Generated at build time * doc/todo.txt, doc/version5.txt: Irrelevant to Neovim --- runtime/doc/help.txt | 2 +- runtime/doc/index.txt | 2 +- runtime/doc/message.txt | 2 +- runtime/doc/repeat.txt | 8 ++++++-- runtime/doc/starting.txt | 4 ++-- runtime/doc/syntax.txt | 4 ++-- runtime/doc/usr_29.txt | 2 +- runtime/doc/various.txt | 2 +- 8 files changed, 15 insertions(+), 11 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/help.txt b/runtime/doc/help.txt index fd5b9a99ec..305eaea924 100644 --- a/runtime/doc/help.txt +++ b/runtime/doc/help.txt @@ -1,4 +1,4 @@ -*help.txt* For Vim version 7.4. Last change: 2016 Feb 22 +*help.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM - main help file k diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt index a974aa3d08..9efd107226 100644 --- a/runtime/doc/index.txt +++ b/runtime/doc/index.txt @@ -1,4 +1,4 @@ -*index.txt* For Vim version 7.4. Last change: 2016 Feb 24 +*index.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/message.txt b/runtime/doc/message.txt index 114bb61d99..7ceddeb674 100644 --- a/runtime/doc/message.txt +++ b/runtime/doc/message.txt @@ -1,4 +1,4 @@ -*message.txt* For Vim version 7.4. Last change: 2013 Feb 23 +*message.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 4db3580efa..527b84c992 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 24 +*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 26 VIM REFERENCE MANUAL by Bram Moolenaar @@ -212,6 +212,10 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. 'runtimepath'. And the directory found is added to 'runtimepath'. + If you have a directory under 'packpath' that doesn't + actually have a plugin file, just create an empty one. + This will still add the directory to 'runtimepath'. + Note that {name} is the directory name, not the name of the .vim file. If the "{name}/plugin" directory contains more than one file they are all sourced. @@ -548,7 +552,7 @@ Additionally, these commands can be used: About the additional commands in debug mode: - There is no command-line completion for them, you get the completion for the normal Ex commands only. -- You can shorten them, up to a single character, unless more then one command +- You can shorten them, up to a single character, unless more than one command starts with the same letter. "f" stands for "finish", use "fr" for "frame". - Hitting will repeat the previous one. When doing another command, this is reset (because it's not clear what you want to repeat). diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index 0508c52540..5db65cfaad 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Feb 21 +*starting.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM REFERENCE MANUAL by Bram Moolenaar @@ -714,7 +714,7 @@ There are several ways to exit Vim: - Use `:cquit`. Also when there are changes. When using `:cquit` or when there was an error message Vim exits with exit -code 1. Errors can be avoide by using `:silent!`. +code 1. Errors can be avoided by using `:silent!`. ============================================================================== 6. Saving settings *save-settings* diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index f7e9ece3d8..b6f1e4d856 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 7.4. Last change: 2016 Feb 24 +*syntax.txt* For Vim version 7.4. Last change: 2016 Feb 25 VIM REFERENCE MANUAL by Bram Moolenaar @@ -2886,7 +2886,7 @@ You may wish to embed languages into sh. I'll give an example courtesy of Lorance Stinson on how to do this with awk as an example. Put the following file into $HOME/.config/nvim/after/syntax/sh/awkembed.vim: > - " AWK Embedding: {{{1 + " AWK Embedding: " ============== " Shamelessly ripped from aspperl.vim by Aaron Hope. if exists("b:current_syntax") diff --git a/runtime/doc/usr_29.txt b/runtime/doc/usr_29.txt index e495aad06d..9eb66ce83c 100644 --- a/runtime/doc/usr_29.txt +++ b/runtime/doc/usr_29.txt @@ -1,4 +1,4 @@ -*usr_29.txt* For Vim version 7.4. Last change: 2008 Jun 28 +*usr_29.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM USER MANUAL - by Bram Moolenaar diff --git a/runtime/doc/various.txt b/runtime/doc/various.txt index e6b05e1ab1..b3e5e2db03 100644 --- a/runtime/doc/various.txt +++ b/runtime/doc/various.txt @@ -1,4 +1,4 @@ -*various.txt* For Vim version 7.4. Last change: 2016 Feb 18 +*various.txt* For Vim version 7.4. Last change: 2016 Feb 27 VIM REFERENCE MANUAL by Bram Moolenaar -- cgit From 67d8e586318a3f2f13df22f9a3b25c6d8a109e6c Mon Sep 17 00:00:00 2001 From: James McCoy Date: Thu, 28 Apr 2016 20:47:27 -0400 Subject: vim-patch:7.4.1480 Problem: Cannot add a pack direcory without loading a plugin. Solution: Add the :packadd command. https://github.com/vim/vim/commit/91715873d19a1859c08eeded7848113596e2f2bd --- runtime/doc/repeat.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'runtime/doc') diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 527b84c992..b9dee8d261 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -398,7 +398,7 @@ A Vim package is a directory that contains one or more plugins. The advantages over normal plugins: - A package can be downloaded as an archive and unpacked in its own directory. That makes it easy to updated and/or remove. -- A package can be a git, mercurial, etc. respository. That makes it really +- A package can be a git, mercurial, etc. repository. That makes it really easy to update. - A package can contain multiple plugins that depend on each other. - A package can contain plugins that are automatically loaded on startup and @@ -428,6 +428,8 @@ In the example Vim will find "my/ever/always/plugin/always.vim" and adds If the "always" plugin kicks in and sets the 'filetype' to "always", Vim will find the syntax/always.vim file, because its directory is in 'runtimepath'. +Vim will also load ftdetect files, like with |:loadplugin|. + *load-plugin* To load an optional plugin from a pack use the `:loadplugin` command: > :loadplugin mydebug -- cgit From 2f72f34f0407dcdf189bb4f3a4b79b51e96744bf Mon Sep 17 00:00:00 2001 From: James McCoy Date: Thu, 28 Apr 2016 22:58:24 -0400 Subject: vim-patch:7.4.1486 Problem: ":loadplugin" is not optimal, some people find it confusing. Solution: Only use ":packadd" with an optional "!". https://github.com/vim/vim/commit/f3654827368e6204608036353a0360e9e7c21e02 --- runtime/doc/repeat.txt | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index b9dee8d261..bee05d8efa 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -418,6 +418,12 @@ You would now have these files under ~/.local/share/nvim/site: pack/my/ever/always/syntax/always.vim pack/my/opt/mydebug/plugin/debugger.vim +If you don't have a package but a single plugin, you need to create the extra +directory level: + % mkdir -p ~/.local/share/nvim/site/pack/my/ever/always + % cd ~/.local/share/nvim/site/pack/my/ever/always + % unzip /tmp/myplugin.zip + When Vim starts up it scans all directories in 'packpath' for plugins under the "ever" directory and loads them. When found that directory is added to 'runtimepath'. @@ -428,11 +434,11 @@ In the example Vim will find "my/ever/always/plugin/always.vim" and adds If the "always" plugin kicks in and sets the 'filetype' to "always", Vim will find the syntax/always.vim file, because its directory is in 'runtimepath'. -Vim will also load ftdetect files, like with |:loadplugin|. +Vim will also load ftdetect files, like with |:packadd|. - *load-plugin* -To load an optional plugin from a pack use the `:loadplugin` command: > - :loadplugin mydebug + *pack-add* +To load an optional plugin from a pack use the `:packadd` command: > + :packadd mydebug This could be done inside always.vim, if some conditions are met. Or you could add this command to your |.vimrc|. -- cgit From 5f3813daf4e68a354800bdf553e75899cf24afba Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 10:02:49 -0400 Subject: vim-patch:328da0d Update runtime files. https://github.com/vim/vim/commit/328da0dcb7be34b594725eef6dc98d3ea6516d69 Ignore changes to * doc/channel.txt, doc/eval.txt: Channel related docs * doc/tags: Generated at build time * doc/todo.txt: Irrelevant to Neovim --- runtime/doc/eval.txt | 2 +- runtime/doc/index.txt | 4 ++-- runtime/doc/repeat.txt | 34 +++++++++++++++++++++------------- runtime/doc/starting.txt | 2 +- 4 files changed, 25 insertions(+), 17 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 04aff0b3bf..146f62c770 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Feb 23 +*eval.txt* For Vim version 7.4. Last change: 2016 Mar 03 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt index 9efd107226..eff03c8daf 100644 --- a/runtime/doc/index.txt +++ b/runtime/doc/index.txt @@ -1,4 +1,4 @@ -*index.txt* For Vim version 7.4. Last change: 2016 Feb 27 +*index.txt* For Vim version 7.4. Last change: 2016 Mar 04 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1317,7 +1317,6 @@ tag command action ~ |:lnfile| :lnf[ile] go to first location in next file |:lnoremap| :ln[oremap] like ":noremap!" but includes Lang-Arg mode |:loadkeymap| :loadk[eymap] load the following keymaps until EOF -|:loadplugin| :loadp[lugin] load a plugin from 'packpath' |:loadview| :lo[adview] load view for current window from a file |:lockmarks| :loc[kmarks] following command keeps marks where they are |:lockvar| :lockv[ar] lock variables @@ -1379,6 +1378,7 @@ tag command action ~ |:ounmap| :ou[nmap] like ":unmap" but for Operator-pending mode |:ounmenu| :ounme[nu] remove menu for Operator-pending mode |:ownsyntax| :ow[nsyntax] set new local syntax highlight for this window +|:packadd| :pa[ckadd] add a plugin from 'packpath' |:pclose| :pc[lose] close preview window |:pedit| :ped[it] edit file in the preview window |:print| :p[rint] print lines diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index bee05d8efa..a7873ce002 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Feb 26 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 04 VIM REFERENCE MANUAL by Bram Moolenaar @@ -204,23 +204,31 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. When 'verbose' is two or higher, there is a message about each searched file. - *:loadp* *:loadplugin* -:loadp[lugin] {name} Search for an optional plugin directory and source the - plugin files found. It is similar to: > - :runtime pack/*/opt/{name}/plugin/*.vim -< However, `:loadplugin` uses 'packpath' instead of - 'runtimepath'. And the directory found is added to - 'runtimepath'. - - If you have a directory under 'packpath' that doesn't - actually have a plugin file, just create an empty one. - This will still add the directory to 'runtimepath'. + *:pa* *:packadd* +:pa[ckadd][!] {name} Search for an optional plugin directory in 'packpath' + and source any plugin files found. The directory must + match: + pack/*/opt/{name} ~ + The directory is added to 'runtimepath' if it wasn't + there yet. Note that {name} is the directory name, not the name of the .vim file. If the "{name}/plugin" directory contains more than one file they are all sourced. - Also see |load-plugin|. + If the filetype detection was not enabled yet (this + is usually done with a "syntax enable" or "filetype + on" command in your .vimrc file), this will also look + for "{name}/ftdetect/*.vim" files. + + When the optional ! is added no plugin files or + ftdetect scripts are loaded, only the matching + directories are added to 'runtimepath'. This is + useful in your .vimrc. The plugins will then be + loaded during initialization, see |load-plugins|. + + Also see |pack-add|. + :scripte[ncoding] [encoding] *:scripte* *:scriptencoding* *E167* Specify the character encoding used in the script. diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index 5db65cfaad..bd02e21752 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Feb 27 +*starting.txt* For Vim version 7.4. Last change: 2016 Mar 03 VIM REFERENCE MANUAL by Bram Moolenaar -- cgit From 8ecdc571b0cf679c5195088d140f2988bcbe87e1 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 10:12:07 -0400 Subject: vim-patch:7.4.1499 Problem: No error message when :packadd does not find anything. Solution: Add an error message. (Hirohito Higashi) https://github.com/vim/vim/commit/be82c254862e475a582c0717455e1db6bf96b0d0 --- runtime/doc/repeat.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runtime/doc') diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index a7873ce002..122e995f0a 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -204,7 +204,7 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. When 'verbose' is two or higher, there is a message about each searched file. - *:pa* *:packadd* + *:pa* *:packadd* *E919* :pa[ckadd][!] {name} Search for an optional plugin directory in 'packpath' and source any plugin files found. The directory must match: -- cgit From 4ca9e13637d9acfa9660103949062a2d5d9f5bde Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 10:22:53 -0400 Subject: vim-patch:5f148ec Update runtime files. https://github.com/vim/vim/commit/5f148ec0b5a6cedd9129b3abac351034b83cc4f7 Ignore changes to * doc/channel.txt, doc/eval.txt: Channel related docs * doc/tags: Generated at build time * doc/todo.txt: Irrelevant to Neovim --- runtime/doc/eval.txt | 2 +- runtime/doc/os_win32.txt | 27 +++++++++++++++- runtime/doc/repeat.txt | 83 +++++++++++++++++++++++++++++++----------------- runtime/doc/starting.txt | 3 +- 4 files changed, 82 insertions(+), 33 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 146f62c770..4122b27fd8 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Mar 03 +*eval.txt* For Vim version 7.4. Last change: 2016 Mar 07 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/os_win32.txt b/runtime/doc/os_win32.txt index 3c7ca4e36a..5dc276c9df 100644 --- a/runtime/doc/os_win32.txt +++ b/runtime/doc/os_win32.txt @@ -1,4 +1,4 @@ -*os_win32.txt* For Vim version 7.4. Last change: 2014 Sep 25 +*os_win32.txt* For Vim version 7.4. Last change: 2016 Mar 05 VIM REFERENCE MANUAL by George Reilly @@ -75,6 +75,31 @@ The directory of the Vim executable is appended to $PATH. This is mostly to make "!xxd" work, as it is in the Tools menu. And it also means that when executable() returns 1 the executable can actually be executed. +Quotes in file names *win32-quotes* + +Quotes inside a file name (or any other command line argument) can be escaped +with a backslash. E.g. > + vim -c "echo 'foo\"bar'" + +Alternatively use three quotes to get one: > + vim -c "echo 'foo"""bar'" + +The quotation rules are: + +1. A `"` starts quotation. +2. Another `"` or `""` ends quotation. If the quotation ends with `""`, a `"` + is produced at the end of the quoted string. + +Examples, with [] around an argument: + "foo" -> [foo] + "foo"" -> [foo"] + "foo"bar -> [foobar] + "foo" bar -> [foo], [bar] + "foo""bar -> [foo"bar] + "foo"" bar -> [foo"], [bar] + "foo"""bar" -> [foo"bar] + + ============================================================================== 3. Using the mouse *win32-mouse* diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 122e995f0a..ea86be5bf7 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 04 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 07 VIM REFERENCE MANUAL by Bram Moolenaar @@ -405,57 +405,80 @@ Rationale: A Vim package is a directory that contains one or more plugins. The advantages over normal plugins: - A package can be downloaded as an archive and unpacked in its own directory. - That makes it easy to updated and/or remove. + Thus the files are not mixed with files of other plugins. That makes it + easy to update and remove. - A package can be a git, mercurial, etc. repository. That makes it really easy to update. - A package can contain multiple plugins that depend on each other. - A package can contain plugins that are automatically loaded on startup and - ones that are only loaded when needed with `:loadplugin`. + ones that are only loaded when needed with `:packadd`. + + +Using a package and loading automatically ~ Let's assume your Vim files are in the "~/.local/share/nvim/site" directory -and you want to add a package from a zip archive "/tmp/mypack.zip": - % mkdir -p ~/.local/share/nvim/site/pack/my - % cd ~/.local/share/nvim/site/pack/my - % unzip /tmp/mypack.zip +and you want to add a package from a zip archive "/tmp/foopack.zip": + % mkdir -p ~/.local/share/nvim/site/pack/foo + % cd ~/.local/share/nvim/site/pack/foo + % unzip /tmp/foopack.zip -The directory name "my" is arbitrary, you can pick anything you like. +The directory name "foo" is arbitrary, you can pick anything you like. You would now have these files under ~/.local/share/nvim/site: - pack/my/README.txt - pack/my/ever/always/plugin/always.vim - pack/my/ever/always/syntax/always.vim - pack/my/opt/mydebug/plugin/debugger.vim + pack/foo/README.txt + pack/foo/ever/foobar/plugin/foo.vim + pack/foo/ever/foobar/syntax/some.vim + pack/foo/opt/foodebug/plugin/debugger.vim + +When Vim starts up, after processing your .vimrc, it scans all directories in +'packpath' for plugins under the "pack/*/ever" directory and loads them. The +directory is added to 'runtimepath'. + +In the example Vim will find "pack/foo/ever/foobar/plugin/foo.vim" and adds +"~/.local/share/nvim/site/pack/foo/ever/foobar" to 'runtimepath'. + +If the "foobar" plugin kicks in and sets the 'filetype' to "some", Vim will +find the syntax/some.vim file, because its directory is in 'runtimepath'. + +Vim will also load ftdetect files, if there are any. + +Note that the files under "pack/foo/opt" or not loaded automatically, only the +ones under "pack/foo/ever". See |pack-add| below for how the "opt" directory +is used. + +Loading packages will not happen if loading plugins is disabled, see +|load-plugins|. + + +Using a single plugin and loading it automatically ~ If you don't have a package but a single plugin, you need to create the extra directory level: - % mkdir -p ~/.local/share/nvim/site/pack/my/ever/always - % cd ~/.local/share/nvim/site/pack/my/ever/always - % unzip /tmp/myplugin.zip - -When Vim starts up it scans all directories in 'packpath' for plugins under the -"ever" directory and loads them. When found that directory is added to -'runtimepath'. + % mkdir -p ~/.local/share/nvim/site/pack/foo/ever/foobar + % cd ~/.local/share/nvim/site/pack/foo/ever/foobar + % unzip /tmp/someplugin.zip -In the example Vim will find "my/ever/always/plugin/always.vim" and adds -"~/.local/share/nvim/site/pack/my/ever/always" to 'runtimepath'. +You would now have these files: + pack/foo/ever/foobar/plugin/foo.vim + pack/foo/ever/foobar/syntax/some.vim -If the "always" plugin kicks in and sets the 'filetype' to "always", Vim will -find the syntax/always.vim file, because its directory is in 'runtimepath'. +From here it works like above. -Vim will also load ftdetect files, like with |:packadd|. +Optional plugins ~ *pack-add* To load an optional plugin from a pack use the `:packadd` command: > - :packadd mydebug -This could be done inside always.vim, if some conditions are met. -Or you could add this command to your |.vimrc|. + :packadd foodebug +This searches for "pack/*/opt/foodebug" in 'packpath' and will find +~/.local/share/nvim/site/pack/foo/opt/foodebug/plugin/debugger.vim and source +it. + +This could be done inside always.vim, if some conditions are met. Or you +could add this command to your |.vimrc|. It is perfectly normal for a package to only have files in the "opt" directory. You then need to load each plugin when you want to use it. -Loading packages will not happen if loading plugins is disabled, see -|load-plugins|. - ============================================================================== 6. Debugging scripts *debug-scripts* diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index bd02e21752..bda5254663 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Mar 03 +*starting.txt* For Vim version 7.4. Last change: 2016 Mar 05 VIM REFERENCE MANUAL by Bram Moolenaar @@ -41,6 +41,7 @@ filename One or more file names. The first one will be the current nvim -- -filename < All arguments after the "--" will be interpreted as file names, no other options or "+command" argument can follow. + For behavior of quotes on MS-Windows, see |win32-quotes|. *--* - This argument can mean two things, depending on whether Ex -- cgit From 1f54d253e169fbc483cc485f9b3092a8da1f62db Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 10:35:38 -0400 Subject: vim-patch:7.4.1528 Problem: Using "ever" for packages is confusing. Solution: Use "start", as it's related to startup. https://github.com/vim/vim/commit/af1a0e371e739f8dff337fd31da0ff8ffb347b43 --- runtime/doc/repeat.txt | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index ea86be5bf7..8fcecfd5c0 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 07 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 09 VIM REFERENCE MANUAL by Bram Moolenaar @@ -426,16 +426,16 @@ The directory name "foo" is arbitrary, you can pick anything you like. You would now have these files under ~/.local/share/nvim/site: pack/foo/README.txt - pack/foo/ever/foobar/plugin/foo.vim - pack/foo/ever/foobar/syntax/some.vim + pack/foo/start/foobar/plugin/foo.vim + pack/foo/start/foobar/syntax/some.vim pack/foo/opt/foodebug/plugin/debugger.vim When Vim starts up, after processing your .vimrc, it scans all directories in -'packpath' for plugins under the "pack/*/ever" directory and loads them. The +'packpath' for plugins under the "pack/*/start" directory and loads them. The directory is added to 'runtimepath'. -In the example Vim will find "pack/foo/ever/foobar/plugin/foo.vim" and adds -"~/.local/share/nvim/site/pack/foo/ever/foobar" to 'runtimepath'. +In the example Vim will find "pack/foo/start/foobar/plugin/foo.vim" and adds +"~/.local/share/nvim/site/pack/foo/start/foobar" to 'runtimepath'. If the "foobar" plugin kicks in and sets the 'filetype' to "some", Vim will find the syntax/some.vim file, because its directory is in 'runtimepath'. @@ -443,7 +443,7 @@ find the syntax/some.vim file, because its directory is in 'runtimepath'. Vim will also load ftdetect files, if there are any. Note that the files under "pack/foo/opt" or not loaded automatically, only the -ones under "pack/foo/ever". See |pack-add| below for how the "opt" directory +ones under "pack/foo/start". See |pack-add| below for how the "opt" directory is used. Loading packages will not happen if loading plugins is disabled, see @@ -454,13 +454,13 @@ Using a single plugin and loading it automatically ~ If you don't have a package but a single plugin, you need to create the extra directory level: - % mkdir -p ~/.local/share/nvim/site/pack/foo/ever/foobar - % cd ~/.local/share/nvim/site/pack/foo/ever/foobar + % mkdir -p ~/.local/share/nvim/site/pack/foo/start/foobar + % cd ~/.local/share/nvim/site/pack/foo/start/foobar % unzip /tmp/someplugin.zip You would now have these files: - pack/foo/ever/foobar/plugin/foo.vim - pack/foo/ever/foobar/syntax/some.vim + pack/foo/start/foobar/plugin/foo.vim + pack/foo/start/foobar/syntax/some.vim From here it works like above. -- cgit From ea18b4a60f3b89d261c46b030d3d026ddad864bb Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 20 Jun 2016 10:37:19 -0400 Subject: vim-patch:77cdfd1 Updated runtime files. https://github.com/vim/vim/commit/77cdfd10382e01cc51f4ba1a9177032351843151 Ignore changes to: * doc/channel.txt, doc/eval.txt: Channel related docs * doc/options.txt: GUI related docs * doc/tags: Generated at build time * doc/todo.txt: Irrelevant for Neovim --- runtime/doc/change.txt | 6 ++++-- runtime/doc/eval.txt | 2 +- runtime/doc/options.txt | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt index 4565cdf63e..2ccb9188a9 100644 --- a/runtime/doc/change.txt +++ b/runtime/doc/change.txt @@ -1,4 +1,4 @@ -*change.txt* For Vim version 7.4. Last change: 2016 Feb 10 +*change.txt* For Vim version 7.4. Last change: 2016 Mar 08 VIM REFERENCE MANUAL by Bram Moolenaar @@ -108,7 +108,9 @@ is an error when 'cpoptions' includes the 'E' flag. *J* J Join [count] lines, with a minimum of two lines. Remove the indent and insert up to two spaces (see - below). + below). Fails when on the last line of the buffer. + If [count] is too big it is reduce to the number of + lines available. *v_J* {Visual}J Join the highlighted lines, with a minimum of two diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 4122b27fd8..712a0d7e5a 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Mar 07 +*eval.txt* For Vim version 7.4. Last change: 2016 Mar 08 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 887cff0707..76ecb57e34 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 7.4. Last change: 2016 Feb 24 +*options.txt* For Vim version 7.4. Last change: 2016 Mar 08 VIM REFERENCE MANUAL by Bram Moolenaar -- cgit From 53613e7fcd27feda32844904f4ef88bf82841015 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Tue, 21 Jun 2016 23:13:46 -0400 Subject: vim-patch:7.4.1553 Problem: ":runtime" does not use 'packpath'. Solution: Add "what" argument. https://github.com/vim/vim/commit/8dcf259d904cfb965d31841dc74a5cfaf5a351d9 --- runtime/doc/repeat.txt | 36 +++++++++++++++++++++++++++++++----- 1 file changed, 31 insertions(+), 5 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 8fcecfd5c0..5357090b1b 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -174,10 +174,12 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. commands. *:ru* *:runtime* -:ru[ntime][!] {file} .. +:ru[ntime][!] [where] {file} .. Read Ex commands from {file} in each directory given - by 'runtimepath'. There is no error for non-existing - files. Example: > + by 'runtimepath' and/or 'packpath'. There is no error + for non-existing files. + + Example: > :runtime syntax/c.vim < There can be multiple {file} arguments, separated by @@ -191,6 +193,15 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. When it is not included only the first found file is sourced. + When [where] is omitted only 'runtimepath' is used. + Other values: + START search under "start" in 'packpath' + OPT search under "opt" in 'packpath' + PACK search under "start" and "opt" in + 'packpath' + ALL first use 'runtimepath', then search + under "start" and "opt" in 'packpath' + When {file} contains wildcards it is expanded to all matching files. Example: > :runtime! plugin/*.vim @@ -229,6 +240,16 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. Also see |pack-add|. +:packloadall[!] Load all packages in the "start" directories under + 'packpath'. The directories found are added to + 'runtimepath'. + This normally done during startup, after loading your + .vimrc file. With this command it can be done + earlier. + Packages will be loaded only once. After this command + it won't happen again. When the optional ! is added + this command will load packages even when done before. + See |packages|. :scripte[ncoding] [encoding] *:scripte* *:scriptencoding* *E167* Specify the character encoding used in the script. @@ -446,8 +467,13 @@ Note that the files under "pack/foo/opt" or not loaded automatically, only the ones under "pack/foo/start". See |pack-add| below for how the "opt" directory is used. -Loading packages will not happen if loading plugins is disabled, see -|load-plugins|. +Loading packages automatically will not happen if loading plugins is disabled, +see |load-plugins|. + +To load packages earlier, so that 'runtimepath' gets updated: > + :packloadall +This also works when loading plugins is disabled. The automatic loading will +only happen once. Using a single plugin and loading it automatically ~ -- cgit From 0b2633b1bb3a73dae7679bf9bec0dc9f5e75fe44 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Wed, 22 Jun 2016 20:24:20 -0400 Subject: vim-patch:e18c0b3 Updated runtime files. https://github.com/vim/vim/commit/e18c0b39815c5a746887a509c2cd9f11fadaba07 Ignore changes to * doc/channel.txt, runtime/tools/demoserver.py: Channel related changes * doc/if_lua.txt, doc/if_perl.txt, doc/if_pyth.txt, doc/if_ruby.txt, doc/if_tcl.txt, doc/todo.txt: Irrelevant to Neovim * doc/tags: Generated at build time --- runtime/doc/helphelp.txt | 5 ++++- runtime/doc/index.txt | 3 ++- runtime/doc/quickfix.txt | 6 +++++- runtime/doc/repeat.txt | 11 +++++++---- runtime/doc/syntax.txt | 8 ++++---- runtime/doc/usr_41.txt | 6 ++++-- runtime/doc/various.txt | 3 ++- 7 files changed, 28 insertions(+), 14 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt index f3533b8815..2a098544c6 100644 --- a/runtime/doc/helphelp.txt +++ b/runtime/doc/helphelp.txt @@ -1,4 +1,4 @@ -*helphelp.txt* For Vim version 7.4. Last change: 2014 Sep 19 +*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 12 VIM REFERENCE MANUAL by Bram Moolenaar @@ -188,6 +188,9 @@ command: > *E154* *E150* *E151* *E152* *E153* *E670* :helpt[ags] [++t] {dir} Generate the help tags file(s) for directory {dir}. + When {dir} is ALL then all "doc" directories in + 'runtimepath' will be used. + All "*.txt" and "*.??x" files in the directory and sub-directories are scanned for a help tag definition in between stars. The "*.??x" files are for diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt index eff03c8daf..bd2df5d1e5 100644 --- a/runtime/doc/index.txt +++ b/runtime/doc/index.txt @@ -1,4 +1,4 @@ -*index.txt* For Vim version 7.4. Last change: 2016 Mar 04 +*index.txt* For Vim version 7.4. Last change: 2016 Mar 12 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1379,6 +1379,7 @@ tag command action ~ |:ounmenu| :ounme[nu] remove menu for Operator-pending mode |:ownsyntax| :ow[nsyntax] set new local syntax highlight for this window |:packadd| :pa[ckadd] add a plugin from 'packpath' +|:packloadall| :packl[oadall] load all packages under 'packpath' |:pclose| :pc[lose] close preview window |:pedit| :ped[it] edit file in the preview window |:print| :p[rint] print lines diff --git a/runtime/doc/quickfix.txt b/runtime/doc/quickfix.txt index 317226108f..3b54faf18e 100644 --- a/runtime/doc/quickfix.txt +++ b/runtime/doc/quickfix.txt @@ -1,4 +1,4 @@ -*quickfix.txt* For Vim version 7.4. Last change: 2016 Jan 21 +*quickfix.txt* For Vim version 7.4. Last change: 2016 Mar 19 VIM REFERENCE MANUAL by Bram Moolenaar @@ -49,6 +49,10 @@ The following quickfix commands can be used. The location list commands are similar to the quickfix commands, replacing the 'c' prefix in the quickfix command with 'l'. + *E924* +If the current window was closed by an |autocommand| while processing a +location list command, it will be aborted. + *:cc* :cc[!] [nr] Display error [nr]. If [nr] is omitted, the same error is displayed again. Without [!] this doesn't diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 5357090b1b..2a20a42c16 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 09 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 15 VIM REFERENCE MANUAL by Bram Moolenaar @@ -240,15 +240,18 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. Also see |pack-add|. + *:packl* *:packloadall* :packloadall[!] Load all packages in the "start" directories under 'packpath'. The directories found are added to 'runtimepath'. - This normally done during startup, after loading your - .vimrc file. With this command it can be done - earlier. + This is normally done automatically during startup, + after loading your .vimrc file. With this command it + can be done earlier. Packages will be loaded only once. After this command it won't happen again. When the optional ! is added this command will load packages even when done before. + An Error only causes sourcing the script where it + happens to be aborted, further plugins will be loaded. See |packages|. :scripte[ncoding] [encoding] *:scripte* *:scriptencoding* *E167* diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index b6f1e4d856..9bec855190 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 7.4. Last change: 2016 Feb 25 +*syntax.txt* For Vim version 7.4. Last change: 2016 Mar 12 VIM REFERENCE MANUAL by Bram Moolenaar @@ -4518,9 +4518,9 @@ in their own color. :colo[rscheme] {name} Load color scheme {name}. This searches 'runtimepath' for the file "colors/{name}.vim". The first one that is found is loaded. - To see the name of the currently active color scheme: > - :colo -< The name is also stored in the g:colors_name variable. + Also searches all plugins in 'packpath', first below + "start" and then under "opt". + Doesn't work recursively, thus you can't use ":colorscheme" in a color scheme script. After the color scheme has been loaded the diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt index a14e722328..f57e237a01 100644 --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -1,4 +1,4 @@ -*usr_41.txt* For Vim version 7.4. Last change: 2016 Feb 14 +*usr_41.txt* For Vim version 7.4. Last change: 2016 Mar 15 VIM USER MANUAL - by Bram Moolenaar @@ -889,9 +889,11 @@ Mappings: *mapping-functions* wildmenumode() check if the wildmode is active Testing: *test-functions* - assert_equal() assert that two expressions values are equal + assert_equal() assert that two expressions values are equal assert_false() assert that an expression is false assert_true() assert that an expression is true + assert_exception() assert that a command throws an exception + assert_fails() assert that a function call fails Various: *various-functions* mode() get current editing mode diff --git a/runtime/doc/various.txt b/runtime/doc/various.txt index b3e5e2db03..eb813866da 100644 --- a/runtime/doc/various.txt +++ b/runtime/doc/various.txt @@ -1,4 +1,4 @@ -*various.txt* For Vim version 7.4. Last change: 2016 Feb 27 +*various.txt* For Vim version 7.4. Last change: 2016 Mar 20 VIM REFERENCE MANUAL by Bram Moolenaar @@ -375,6 +375,7 @@ B *+termguicolors* 24-bit color in xterm-compatible terminals support N *+termresponse* support for |t_RV| and |v:termresponse| N *+textobjects* |text-objects| selection *+tgetent* non-Unix only: able to use external termcap +N *+timers* the |timer_start()| function N *+title* Setting the window 'title' and 'icon' N *+toolbar* |gui-toolbar| N *+user_commands* User-defined commands. |user-commands| -- cgit From 5f471b24865755fc00017c0470dc987bccd4405b Mon Sep 17 00:00:00 2001 From: James McCoy Date: Wed, 22 Jun 2016 22:05:27 -0400 Subject: vim-patch:4f3f668 Updated runtime files. https://github.com/vim/vim/commit/4f3f668c8486444e53163c29d2fc79bf47eb3c82 Ignore changes to * doc/channel.txt: Channel related docs * doc/tags: Generated at build time * doc/todo.txt: Irrelevant to Neovim --- runtime/doc/autocmd.txt | 2 +- runtime/doc/eval.txt | 3 +- runtime/doc/helphelp.txt | 4 +- runtime/doc/options.txt | 7 ++-- runtime/doc/repeat.txt | 103 +++++++++++++++++++++++++++++++++++++++++------ runtime/doc/starting.txt | 9 +++-- 6 files changed, 105 insertions(+), 23 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt index 6641732679..dc37ff1d6d 100644 --- a/runtime/doc/autocmd.txt +++ b/runtime/doc/autocmd.txt @@ -1,4 +1,4 @@ -*autocmd.txt* For Vim version 7.4. Last change: 2015 Dec 05 +*autocmd.txt* For Vim version 7.4. Last change: 2016 Mar 26 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 712a0d7e5a..0bd5c04344 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Mar 08 +*eval.txt* For Vim version 7.4. Last change: 2016 Mar 26 VIM REFERENCE MANUAL by Bram Moolenaar @@ -7408,6 +7408,7 @@ unix Unix version of Vim. user_commands User-defined commands. vertsplit Compiled with vertically split windows |:vsplit|. vim_starting True while initial source'ing takes place. |startup| + *vim_starting* virtualedit Compiled with 'virtualedit' option. visual Compiled with Visual mode. visualextra Compiled with extra Visual mode commands. diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt index 2a098544c6..95d280c529 100644 --- a/runtime/doc/helphelp.txt +++ b/runtime/doc/helphelp.txt @@ -1,4 +1,4 @@ -*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 12 +*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 26 VIM REFERENCE MANUAL by Bram Moolenaar @@ -199,9 +199,11 @@ command: > sorted. When there are duplicates an error message is given. An existing tags file is silently overwritten. + The optional "++t" argument forces adding the "help-tags" tag. This is also done when the {dir} is equal to $VIMRUNTIME/doc. + To rebuild the help tags in the runtime directory (requires write permission there): > :helptags $VIMRUNTIME/doc diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 76ecb57e34..669f74186c 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 7.4. Last change: 2016 Mar 08 +*options.txt* For Vim version 7.4. Last change: 2016 Mar 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -2458,8 +2458,8 @@ A jump table for the options with a short description can be found at |Q_op|. file only, the option is not changed. When 'binary' is set, the value of 'fileformats' is not used. - Note that when Vim starts up with an empty buffer this option is not - used. Set 'fileformat' in your vimrc instead. + When Vim starts up with an empty buffer the first item is used. You + can overrule this by setting 'fileformat' in your .vimrc. For systems with a Dos-like (), when reading files that are ":source"ed and for vimrc files, automatic detection may be @@ -4238,6 +4238,7 @@ A jump table for the options with a short description can be found at |Q_op|. written. A ":set nomodified" command also resets the original values to the current values and the 'modified' option will be reset. + Similarly for 'eol' and 'bomb'. This option is not set when a change is made to the buffer as the result of a BufNewFile, BufRead/BufReadPost, BufWritePost, FileAppendPost or VimLeave autocommand event. See |gzip-example| for diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 2a20a42c16..a5785fb714 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 15 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 26 VIM REFERENCE MANUAL by Bram Moolenaar @@ -8,13 +8,14 @@ Repeating commands, Vim scripts and debugging *repeating* Chapter 26 of the user manual introduces repeating |usr_26.txt|. -1. Single repeats |single-repeat| -2. Multiple repeats |multi-repeat| -3. Complex repeats |complex-repeat| -4. Using Vim scripts |using-scripts| -5. Using Vim packages |packages| -6. Debugging scripts |debug-scripts| -7. Profiling |profiling| +1. Single repeats |single-repeat| +2. Multiple repeats |multi-repeat| +3. Complex repeats |complex-repeat| +4. Using Vim scripts |using-scripts| +5. Using Vim packages |packages| +6. Creating Vim packages |package-create| +7. Debugging scripts |debug-scripts| +8. Profiling |profiling| ============================================================================== 1. Single repeats *single-repeat* @@ -466,7 +467,7 @@ find the syntax/some.vim file, because its directory is in 'runtimepath'. Vim will also load ftdetect files, if there are any. -Note that the files under "pack/foo/opt" or not loaded automatically, only the +Note that the files under "pack/foo/opt" are not loaded automatically, only the ones under "pack/foo/start". See |pack-add| below for how the "opt" directory is used. @@ -502,14 +503,90 @@ This searches for "pack/*/opt/foodebug" in 'packpath' and will find ~/.local/share/nvim/site/pack/foo/opt/foodebug/plugin/debugger.vim and source it. -This could be done inside always.vim, if some conditions are met. Or you -could add this command to your |.vimrc|. +This could be done if some conditions are met. For example, depending on +whether Vim supports a feature or a dependency is missing. + +You can also load an optional plugin at startup, by putting this command in +your |.vimrc|: > + :packadd! foodebug +The extra "!" is so that the plugin isn't loaded with Vim was started with +|--noplugin|. It is perfectly normal for a package to only have files in the "opt" directory. You then need to load each plugin when you want to use it. + +Where to put what ~ + +Since color schemes, loaded with `:colorscheme`, are found below +"pack/*/start" and "pack/*/opt", you could put them anywhere. We recommend +you put them below "pack/*/opt", for example +".vim/pack/mycolors/opt/dark/colors/very_dark.vim". + +Filetype plugins should go under "pack/*/start", so that they are always +found. Unless you have more than one plugin for a file type and want to +select which one to load with `:packadd`. E.g. depending on the compiler +version: > + if foo_compiler_version > 34 + packadd foo_new + else + packadd foo_old + endif + +The "after" directory is most likely not useful in a package. It's not +disallowed though. + +============================================================================== +6. Creating Vim packages *package-create* + +This assumes you write one or more plugins that you distribute as a package. + +If you have two unrelated plugins you would use two packages, so that Vim +users can chose what they include or not. Or you can decide to use one +package with optional plugins, and tell the user to add the ones he wants with +`:packadd`. + +Decide how you want to distribute the package. You can create an archive or +you could use a repository. An archive can be used by more users, but is a +bit harder to update to a new version. A repository can usually be kept +up-to-date easily, but it requires a program like "git" to be available. +You can do both, github can automatically create an archive for a release. + +Your directory layout would be like this: + start/foobar/plugin/foo.vim " always loaded, defines commands + start/foobar/plugin/bar.vim " always loaded, defines commands + start/foobar/autoload/foo.vim " loaded when foo command used + start/foobar/doc/foo.txt " help for foo.vim + start/foobar/doc/tags " help tags + opt/fooextra/plugin/extra.vim " optional plugin, defines commands + opt/fooextra/autoload/extra.vim " loaded when extra command used + opt/fooextra/doc/extra.txt " help for extra.vim + opt/fooextra/doc/tags " help tags + +This allows for the user to do: > + mkdir ~/.local/share/nvim/site/pack/myfoobar + cd ~/.local/share/nvim/site/pack/myfoobar + git clone https://github.com/you/foobar.git + +Here "myfoobar" is a name that the user can choose, the only condition is that +it differs from other packages. + +In your documentation you explain what the plugins do, and tell the user how +to load the optional plugin: > + :packadd! fooextra + +You could add this packadd command in one of your plugins, to be executed when +the optional plugin is needed. + +Run the `:helptags` command to generate the doc/tags file. Including this +generated file in the package means that the user can drop the package in his +pack directory and the help command works right away. Don't forget to re-run +the command after changing the plugin help: > + :helptags path/start/foobar/doc + :helptags path/opt/fooextra/doc + ============================================================================== -6. Debugging scripts *debug-scripts* +7. Debugging scripts *debug-scripts* Besides the obvious messages that you can add to your scripts to find out what they are doing, Vim offers a debug mode. This allows you to step through a @@ -733,7 +810,7 @@ OBSCURE user, don't use typeahead for debug commands. ============================================================================== -7. Profiling *profile* *profiling* +8. Profiling *profile* *profiling* Profiling means that Vim measures the time that is spent on executing functions and/or scripts. The |+profile| feature is required for this. diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index bda5254663..4829307706 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Mar 05 +*starting.txt* For Vim version 7.4. Last change: 2016 Mar 26 VIM REFERENCE MANUAL by Bram Moolenaar @@ -465,8 +465,8 @@ accordingly. Vim proceeds in this order: use "--cmd 'set noloadplugins'" |--cmd|. Plugin packs are loaded. These are plugins, as above, but found in - 'packpath' directories. Every plugin directory found is added in - 'runtimepath'. See |packages|. + 'packpath' "start" directories. Every plugin directory found is added + in 'runtimepath'. See |packages|. 7. Set 'shellpipe' and 'shellredir' The 'shellpipe' and 'shellredir' options are set according to the @@ -503,8 +503,9 @@ accordingly. Vim proceeds in this order: 14. Execute startup commands If a "-t" flag was given to Vim, the tag is jumped to. The commands given with the |-c| and |+cmd| arguments are executed. - The starting flag is reset, has("vim_starting") will now return zero. If the 'insertmode' option is set, Insert mode is entered. + The starting flag is reset, has("vim_starting") will now return zero. + The |v:vim_did_enter| variable is set to 1. The |VimEnter| autocommands are executed. Some hints on using initializations: -- cgit From 99e51b81e6ef4c62232429159e893bf748fc5fad Mon Sep 17 00:00:00 2001 From: James McCoy Date: Wed, 22 Jun 2016 22:39:30 -0400 Subject: vim-patch:7.4.1649 Problem: The matchit plugin needs to be copied to be used. Solution: Put the matchit plugin in an optional package. https://github.com/vim/vim/commit/aedfcbe1e6c7df6edcd6756d7601bfdec7dd2087 Ignore changes to * Filelist, src/Makefile: Irrelevant to NeoVim * runtime/vimrc_example.vim, runtime/macros/*, runtime/pack/*: matchit is enabled by default in Neovim. --- runtime/doc/usr_05.txt | 58 +++++++++++++++++++++++++++++++++++++++++-------- runtime/doc/usr_toc.txt | 11 +++++----- 2 files changed, 55 insertions(+), 14 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/usr_05.txt b/runtime/doc/usr_05.txt index 5aecf33557..50aa8cc62f 100644 --- a/runtime/doc/usr_05.txt +++ b/runtime/doc/usr_05.txt @@ -1,4 +1,4 @@ -*usr_05.txt* For Vim version 7.4. Last change: 2012 Nov 20 +*usr_05.txt* For Vim version 7.4. Last change: 2016 Mar 25 VIM USER MANUAL - by Bram Moolenaar @@ -12,10 +12,11 @@ Vim's capabilities. Or define your own macros. |05.1| The vimrc file |05.2| The example vimrc file explained |05.3| Simple mappings -|05.4| Adding a plugin -|05.5| Adding a help file -|05.6| The option window -|05.7| Often used options +|05.4| Adding a package +|05.5| Adding a plugin +|05.6| Adding a help file +|05.7| The option window +|05.8| Often used options Next chapter: |usr_06.txt| Using syntax highlighting Previous chapter: |usr_04.txt| Making small changes @@ -245,7 +246,46 @@ The ":map" command (with no arguments) lists your current mappings. At least the ones for Normal mode. More about mappings in section |40.1|. ============================================================================== -*05.4* Adding a plugin *add-plugin* *plugin* +*05.4* Adding a package *add-package* *matchit-install* + +A package is a set of files that you can add to Vim. There are two kinds of +packages: optional and automatically loaded on startup. + +The Vim distribution comes with a few packages that you can optionally use. +For example, the matchit plugin. This plugin makes the "%" command jump to +matching HTML tags, if/else/endif in Vim scripts, etc. Very useful, although +it's not backwards compatible (that's why it is not enabled by default). + +To start using the matchit plugin, add one line to your vimrc file: > + packadd matchit + +That's all! You can also type the command to try it out. Now you can find +help about this plugin: > + :help matchit + +This works, because when `:packadd` loaded the plugin it also added the +package directory in 'runtimepath', so that the help file can be found. + +You can find packages on the Internet in various places. It usually comes as +an archive or as a repository. For an archive you can follow these steps: + 1. create the package directory: > + mkdir -p ~/.local/share/nvim/site/pack/fancy +< "fancy" can be any name of your liking. Use one that describes the + package. + 2. unpack the archive in that directory. This assumes the top + directory in the archive is "start": > + cd ~/.local/share/nvim/site/pack/fancy + unzip /tmp/fancy.zip +< If the archive layout is different make sure that you end up with a + path like this: + ~/.local/share/nvim/site/pack/fancy/start/fancytext/plugin/fancy.vim ~ + Here "fancytext" is the name of the package, it can be anything + else. + +More information about packages can be found here: |packages|. + +============================================================================== +*05.5* Adding a plugin *add-plugin* *plugin* Vim's functionality can be extended by adding plugins. A plugin is nothing more than a Vim script file that is loaded automatically when Vim starts. You @@ -384,7 +424,7 @@ Further reading: |new-filetype| How to detect a new file type. ============================================================================== -*05.5* Adding a help file *add-local-help* +*05.6* Adding a help file *add-local-help* If you are lucky, the plugin you installed also comes with a help file. We will explain how to install the help file, so that you can easily find help @@ -417,7 +457,7 @@ them through the tag. For writing a local help file, see |write-local-help|. ============================================================================== -*05.6* The option window +*05.7* The option window If you are looking for an option that does what you want, you can search in the help files here: |options|. Another way is by using this command: > @@ -456,7 +496,7 @@ border. This is what the 'scrolloff' option does, it specifies an offset from the window border where scrolling starts. ============================================================================== -*05.7* Often used options +*05.8* Often used options There are an awful lot of options. Most of them you will hardly ever use. Some of the more useful ones will be mentioned here. Don't forget you can diff --git a/runtime/doc/usr_toc.txt b/runtime/doc/usr_toc.txt index 77ea462a23..e021b806e3 100644 --- a/runtime/doc/usr_toc.txt +++ b/runtime/doc/usr_toc.txt @@ -1,4 +1,4 @@ -*usr_toc.txt* For Vim version 7.4. Last change: 2010 Jul 20 +*usr_toc.txt* For Vim version 7.4. Last change: 2016 Mar 25 VIM USER MANUAL - by Bram Moolenaar @@ -101,10 +101,11 @@ Read this from start to end to learn the essential commands. |05.1| The vimrc file |05.2| The example vimrc file explained |05.3| Simple mappings - |05.4| Adding a plugin - |05.5| Adding a help file - |05.6| The option window - |05.7| Often used options + |05.4| Adding a package + |05.5| Adding a plugin + |05.6| Adding a help file + |05.7| The option window + |05.8| Often used options |usr_06.txt| Using syntax highlighting |06.1| Switching it on -- cgit From b418f3d6f2f98b446b79b0a1f6cf151f7e26246c Mon Sep 17 00:00:00 2001 From: James McCoy Date: Sun, 26 Jun 2016 13:48:41 -0400 Subject: Move vimball plugin into an optional package --- runtime/doc/pi_vimball.txt | 273 --------------------------------------------- 1 file changed, 273 deletions(-) delete mode 100644 runtime/doc/pi_vimball.txt (limited to 'runtime/doc') diff --git a/runtime/doc/pi_vimball.txt b/runtime/doc/pi_vimball.txt deleted file mode 100644 index bbc74988ca..0000000000 --- a/runtime/doc/pi_vimball.txt +++ /dev/null @@ -1,273 +0,0 @@ -*pi_vimball.txt* For Vim version 7.4. Last change: 2012 Jan 17 - - ---------------- - Vimball Archiver - ---------------- - -Author: Charles E. Campbell, Jr. - (remove NOSPAM from Campbell's email first) -Copyright: (c) 2004-2012 by Charles E. Campbell, Jr. *Vimball-copyright* - The VIM LICENSE (see |copyright|) applies to the files in this - package, including vimballPlugin.vim, vimball.vim, and pi_vimball.txt. - except use "vimball" instead of "VIM". Like anything else that's free, - vimball.vim and its associated files are provided *as is* and comes with - no warranty of any kind, either expressed or implied. No guarantees - of merchantability. No guarantees of suitability for any purpose. By - using this plugin, you agree that in no event will the copyright - holder be liable for any damages resulting from the use of this - software. Use at your own risk! - -============================================================================== -1. Contents *vba* *vimball* *vimball-contents* - - 1. Contents......................................: |vimball-contents| - 2. Vimball Introduction..........................: |vimball-intro| - 3. Vimball Manual................................: |vimball-manual| - MkVimball.....................................: |:MkVimball| - UseVimball....................................: |:UseVimball| - RmVimball.....................................: |:RmVimball| - 4. Vimball History...............................: |vimball-history| - - -============================================================================== -2. Vimball Introduction *vimball-intro* - - Vimball is intended to make life simpler for users of plugins. All - a user needs to do with a vimball is: > - vim someplugin.vba - :so % - :q -< and the plugin and all its components will be installed into their - appropriate directories. Note that one doesn't need to be in any - particular directory when one does this. Plus, any help for the - plugin will also be automatically installed. - - If a user has decided to use the AsNeeded plugin, vimball is smart - enough to put scripts nominally intended for .vim/plugin/ into - .vim/AsNeeded/ instead. - - Removing a plugin that was installed with vimball is really easy: > - vim - :RmVimball someplugin -< This operation is not at all easy for zips and tarballs, for example. - - Vimball examines the user's |'runtimepath'| to determine where to put - the scripts. The first directory mentioned on the runtimepath is - usually used if possible. Use > - :echo &rtp -< to see that directory. - - -============================================================================== -3. Vimball Manual *vimball-manual* - -MAKING A VIMBALL *:MkVimball* - :[range]MkVimball[!] filename [path] - - The range is composed of lines holding paths to files to be included - in your new vimball, omitting the portion of the paths that is - normally specified by the runtimepath (|'rtp'|). As an example: > - plugin/something.vim - doc/something.txt -< using > - :[range]MkVimball filename -< - on this range of lines will create a file called "filename.vba" which - can be used by Vimball.vim to re-create these files. If the - "filename.vba" file already exists, then MkVimball will issue a - warning and not create the file. Note that these paths are relative - to your .vim (vimfiles) directory, and the files should be in that - directory. The vimball plugin normally uses the first |'runtimepath'| - directory that exists as a prefix; don't use absolute paths, unless - the user has specified such a path. - - If you use the exclamation point (!), then MkVimball will create the - "filename.vba" file, overwriting it if it already exists. This - behavior resembles that for |:w|. - - If you wish to force slashes into the filename, that can also be done - by using the exclamation mark (ie. :MkVimball! path/filename). - - The tip at http://vim.wikia.com/wiki/Using_VimBall_with_%27Make%27 - has a good idea on how to automate the production of vimballs using - make. - - -MAKING DIRECTORIES VIA VIMBALLS *g:vimball_mkdir* - - First, the |mkdir()| command is tried (not all systems support it). - - If it doesn't exist, then if g:vimball_mkdir doesn't exist, it is set - as follows: > - |g:netrw_local_mkdir|, if it exists - "mkdir" , if it is executable - "makedir" , if it is executable - Otherwise , it is undefined. -< One may explicitly specify the directory making command using - g:vimball_mkdir. This command is used to make directories that - are needed as indicated by the vimball. - - -CONTROLLING THE VIMBALL EXTRACTION DIRECTORY *g:vimball_home* - - You may override the use of the |'runtimepath'| by specifying a - variable, g:vimball_home. - - *vimball-extract* - vim filename.vba - - Simply editing a Vimball will cause Vimball.vim to tell the user to - source the file to extract its contents. - - Extraction will only proceed if the first line of a putative vimball - file holds the "Vimball Archiver by Charles E. Campbell, Jr., Ph.D." - line. - -LISTING FILES IN A VIMBALL *:VimballList* - - :VimballList - - This command will tell Vimball to list the files in the archive, along - with their lengths in lines. - -MANUALLY INVOKING VIMBALL EXTRACTION *:UseVimball* - - :UseVimball [path] - - This command is contained within the vimball itself; it invokes the - vimball#Vimball() routine which is responsible for unpacking the - vimball. One may choose to execute it by hand instead of sourcing - the vimball; one may also choose to specify a path for the - installation, thereby overriding the automatic choice of the first - existing directory on the |'runtimepath'|. - -REMOVING A VIMBALL *:RmVimball* - - :RmVimball vimballfile [path] - - This command removes all files generated by the specified vimball - (but not any directories it may have made). One may choose a path - for de-installation, too (see |'runtimepath'|); otherwise, the - default is the first existing directory on the |'runtimepath'|. - To implement this, a file (.VimballRecord) is made in that directory - containing a record of what files need to be removed for all vimballs - used thus far. - -PREVENTING LOADING - - If for some reason you don't want to be able to extract plugins - using vimballs: you may prevent the loading of vimball.vim by - putting the following two variables in your <.vimrc>: > - - let g:loaded_vimballPlugin= 1 - let g:loaded_vimball = 1 -< -WINDOWS *vimball-windows* - - Many vimball files are compressed with gzip. Windows, unfortunately, - does not come provided with a tool to decompress gzip'ped files. - Fortunately, there are a number of tools available for Windows users - to un-gzip files: -> - Item Tool/Suite Free Website - ---- ---------- ---- ------- - 7zip tool y http://www.7-zip.org/ - Winzip tool n http://www.winzip.com/downwz.htm - unxutils suite y http://unxutils.sourceforge.net/ - cygwin suite y http://www.cygwin.com/ - GnuWin32 suite y http://gnuwin32.sourceforge.net/ - MinGW suite y http://www.mingw.org/ -< - -============================================================================== -4. Vimball History *vimball-history* {{{1 - - 34 : Sep 22, 2011 * "UseVimball path" now supports a non-full path by - prepending the current directory to it. - 33 : Apr 02, 2011 * Gave priority to *.vmb over *.vba - * Changed silent! to sil! (shorter) - * Safed |'swf'| setting (during vimball extraction, - its now turned off) - 32 : May 19, 2010 * (Christian Brabandt) :so someplugin.vba and - :so someplugin.vba.gz (and the other supported - compression types) now works - * (Jan Steffens) added support for xz compression - * fenc extraction was erroneously picking up the - end of the line number when no file encoding - was present. Fixed. - * By request, beginning the switchover from the vba - extension to vmb. Currently both are supported; - MkVimball, however, now will create *.vmb files. - Feb 11, 2011 * motoyakurotsu reported an error with vimball's - handling of zero-length files - 30 : Dec 08, 2008 * fnameescape() inserted to protect error - messaging using corrupted filenames from - causing problems - * RmVimball supports filenames that would - otherwise be considered to have "magic" - characters (ie. Abc[1].vba) - Feb 18, 2009 * s:Escape(), g:vimball_shq, and g:netrw_shq - removed (shellescape() used directly) - Oct 05, 2009 * (Nikolai Weibull) suggested that MkVimball - be allowed to use slashes in the filename. - 26 : May 27, 2008 * g:vimball_mkdir usage installed. Makes the - $HOME/.vim (or $HOME\vimfiles) directory if - necessary. - May 30, 2008 * (tnx to Bill McCarthy) found and fixed a bug: - vimball wasn't updating plugins to AsNeeded/ - when it should - 25 : Mar 24, 2008 * changed vimball#Vimball() to recognize doc/*.??x - files as help files, too. - Apr 18, 2008 * RmVimball command is now protected by saving and - restoring settings -- in particular, acd was - causing problems as reported by Zhang Shuhan - 24 : Nov 15, 2007 * g:vimball_path_escape used by s:Path() to - prevent certain characters from causing trouble - (defunct: |fnameescape()| and |shellescape()| - now used instead) - 22 : Mar 21, 2007 * uses setlocal instead of set during BufEnter - 21 : Nov 27, 2006 * (tnx to Bill McCarthy) vimball had a header - handling problem and it now changes \s to /s - 20 : Nov 20, 2006 * substitute() calls have all had the 'e' flag - removed. - 18 : Aug 01, 2006 * vimballs now use folding to easily display their - contents. - * if a user has AsNeeded/somefile, then vimball - will extract plugin/somefile to the AsNeeded/ - directory - 17 : Jun 28, 2006 * changes all \s to /s internally for Windows - 16 : Jun 15, 2006 * A. Mechelynck's idea to allow users to specify - installation root paths implemented for - UseVimball, MkVimball, and RmVimball. - * RmVimball implemented - 15 : Jun 13, 2006 * bugfix - 14 : May 26, 2006 * bugfixes - 13 : May 01, 2006 * exists("&acd") used to determine if the acd - option exists - 12 : May 01, 2006 * bugfix - the |'acd'| option is not always defined - 11 : Apr 27, 2006 * VimballList would create missing subdirectories that - the vimball specified were needed. Fixed. - 10 : Apr 27, 2006 * moved all setting saving/restoration to a pair of - functions. Included some more settings in them - which frequently cause trouble. - 9 : Apr 26, 2006 * various changes to support Windows' predilection - for backslashes and spaces in file and directory - names. - 7 : Apr 25, 2006 * bypasses foldenable - * uses more exe and less norm! (:yank :put etc) - * does better at insuring a "Press ENTER" prompt - appears to keep its messages visible - 4 : Mar 31, 2006 * BufReadPost seems to fire twice; BufReadEnter - only fires once, so the "Source this file..." - message is now issued only once. - 3 : Mar 20, 2006 * removed query, now requires sourcing to be - extracted (:so %). Message to that effect - included. - * :VimballList now shows files that would be - extracted. - 2 : Mar 20, 2006 * query, :UseVimball included - 1 : Mar 20, 2006 * initial release - - -============================================================================== -vim:tw=78:ts=8:ft=help:fdm=marker -- cgit From d65563ae9ceebf1ff509e6d8c1638e808a32c002 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Sun, 26 Jun 2016 13:59:41 -0400 Subject: Reword ยง05.4 to describe using the new vimball package MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- runtime/doc/usr_05.txt | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/usr_05.txt b/runtime/doc/usr_05.txt index 50aa8cc62f..464ced72bf 100644 --- a/runtime/doc/usr_05.txt +++ b/runtime/doc/usr_05.txt @@ -246,25 +246,26 @@ The ":map" command (with no arguments) lists your current mappings. At least the ones for Normal mode. More about mappings in section |40.1|. ============================================================================== -*05.4* Adding a package *add-package* *matchit-install* +*05.4* Adding a package *add-package* *vimball-install* A package is a set of files that you can add to Vim. There are two kinds of packages: optional and automatically loaded on startup. The Vim distribution comes with a few packages that you can optionally use. -For example, the matchit plugin. This plugin makes the "%" command jump to -matching HTML tags, if/else/endif in Vim scripts, etc. Very useful, although -it's not backwards compatible (that's why it is not enabled by default). +For example, the vimball plugin. This plugin supports creating and using +vimballs (self-installing Vim plugin archives). -To start using the matchit plugin, add one line to your vimrc file: > - packadd matchit +To start using the vimball plugin, add one line to your vimrc file: > + packadd vimball That's all! You can also type the command to try it out. Now you can find help about this plugin: > - :help matchit + :help vimball This works, because when `:packadd` loaded the plugin it also added the -package directory in 'runtimepath', so that the help file can be found. +package directory in 'runtimepath', so that the help file can be found. The +tags for vimball's help are already created. If you need to generate the help +tags for a package, see the `:helptags` command. You can find packages on the Internet in various places. It usually comes as an archive or as a repository. For an archive you can follow these steps: -- cgit From 3f689ed327be0a391f8cdd15302583c02b04b4e2 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Thu, 7 Jul 2016 23:02:08 -0400 Subject: vim-patch:7db8f6f Updated runtime files. https://github.com/vim/vim/commit/7db8f6f4f85e5d0526d23107b2a5e2334dc23354 Ignore changes to * doc/tags: Generated at build time * doc/channel.txt, doc/todo.txt: Irrelevant to Neovim * pack/dist/opt/matchit/doc/matchit.txt: matchit is enabled by default, so description of how to enable isn't needed. --- runtime/doc/editing.txt | 4 ++-- runtime/doc/eval.txt | 2 +- runtime/doc/helphelp.txt | 6 ++++-- runtime/doc/repeat.txt | 4 ++-- runtime/doc/usr_05.txt | 7 +++---- runtime/doc/usr_25.txt | 10 +++++++--- runtime/doc/usr_41.txt | 3 ++- 7 files changed, 21 insertions(+), 15 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt index 69f834b04d..6f85436ab4 100644 --- a/runtime/doc/editing.txt +++ b/runtime/doc/editing.txt @@ -1,4 +1,4 @@ -*editing.txt* For Vim version 7.4. Last change: 2016 Feb 16 +*editing.txt* For Vim version 7.4. Last change: 2016 Mar 28 VIM REFERENCE MANUAL by Bram Moolenaar @@ -358,7 +358,7 @@ These are the common ones: To avoid the special meaning of the wildcards prepend a backslash. However, on MS-Windows the backslash is a path separator and "path\[abc]" is still seen as a wildcard when "[" is in the 'isfname' option. A simple way to avoid this -is to use "path\[[]abc]". Then the file "path[abc]" literally. +is to use "path\[[]abc]", this matches the file "path\[abc]". *starstar-wildcard* Expanding "**" is possible on Unix, Win32, Mac OS/X and a few other systems. diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 0bd5c04344..3495f9c004 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Mar 26 +*eval.txt* For Vim version 7.4. Last change: 2016 Mar 29 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt index 95d280c529..9654f249fa 100644 --- a/runtime/doc/helphelp.txt +++ b/runtime/doc/helphelp.txt @@ -1,4 +1,4 @@ -*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 26 +*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 28 VIM REFERENCE MANUAL by Bram Moolenaar @@ -254,7 +254,9 @@ The second one finds the English user manual, even when 'helplang' is set to When using command-line completion for the ":help" command, the "@en" extension is only shown when a tag exists for multiple languages. When the -tag only exists for English "@en" is omitted. +tag only exists for English "@en" is omitted. When the first candidate has an +"@ab" extension and it matches the first language in 'helplang' "@ab" is also +omitted. When using |CTRL-]| or ":help!" in a non-English help file Vim will try to find the tag in the same language. If not found then 'helplang' will be used diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index a5785fb714..5a2396669e 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 26 +*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 27 VIM REFERENCE MANUAL by Bram Moolenaar @@ -251,7 +251,7 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. Packages will be loaded only once. After this command it won't happen again. When the optional ! is added this command will load packages even when done before. - An Error only causes sourcing the script where it + An error only causes sourcing the script where it happens to be aborted, further plugins will be loaded. See |packages|. diff --git a/runtime/doc/usr_05.txt b/runtime/doc/usr_05.txt index 464ced72bf..f920fd4591 100644 --- a/runtime/doc/usr_05.txt +++ b/runtime/doc/usr_05.txt @@ -1,4 +1,4 @@ -*usr_05.txt* For Vim version 7.4. Last change: 2016 Mar 25 +*usr_05.txt* For Vim version 7.4. Last change: 2016 Mar 28 VIM USER MANUAL - by Bram Moolenaar @@ -340,10 +340,9 @@ Then copy the file to your plugin directory: Example for Unix (assuming you didn't have a plugin directory yet): > mkdir -p ~/.local/share/nvim/site/plugin - cp /usr/local/share/vim/vim60/macros/justify.vim ~/.local/share/nvim/site/plugin + cp /tmp/yourplugin.vim ~/.local/share/nvim/site/plugin -That's all! Now you can use the commands defined in this plugin to justify -text. +That's all! Now you can use the commands defined in this plugin. Instead of putting plugins directly into the plugin/ directory, you may better organize them by putting them into subdirectories under plugin/. diff --git a/runtime/doc/usr_25.txt b/runtime/doc/usr_25.txt index 23d76a8b0f..24420353dd 100644 --- a/runtime/doc/usr_25.txt +++ b/runtime/doc/usr_25.txt @@ -1,4 +1,4 @@ -*usr_25.txt* For Vim version 7.4. Last change: 2014 Oct 29 +*usr_25.txt* For Vim version 7.4. Last change: 2016 Mar 28 VIM USER MANUAL - by Bram Moolenaar @@ -196,12 +196,16 @@ Vim has no built-in way of justifying text. However, there is a neat macro package that does the job. To use this package, execute the following command: > - :runtime macros/justify.vim + :packadd justify + +Or put this line in your |vimrc|: > + + packadd! justify This Vim script file defines a new visual command "_j". To justify a block of text, highlight the text in Visual mode and then execute "_j". Look in the file for more explanations. To go there, do "gf" on this name: -$VIMRUNTIME/macros/justify.vim. +$VIMRUNTIME/pack/dist/opt/justify/plugin/justify.vim. An alternative is to filter the text through an external program. Example: > diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt index f57e237a01..f00f03bae8 100644 --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -1,4 +1,4 @@ -*usr_41.txt* For Vim version 7.4. Last change: 2016 Mar 15 +*usr_41.txt* For Vim version 7.4. Last change: 2016 Mar 27 VIM USER MANUAL - by Bram Moolenaar @@ -890,6 +890,7 @@ Mappings: *mapping-functions* Testing: *test-functions* assert_equal() assert that two expressions values are equal + assert_match() assert that a pattern matches the value assert_false() assert that an expression is false assert_true() assert that an expression is true assert_exception() assert that a command throws an exception -- cgit From e686b613ecd349265e17d9c1f481cafac4935aef Mon Sep 17 00:00:00 2001 From: James McCoy Date: Thu, 7 Jul 2016 23:26:00 -0400 Subject: vim-patch:03413f4 Updated runtime files. https://github.com/vim/vim/commit/03413f44167c4b5cd0012def9bb331e2518c83cf Ignore changes to * doc/Makefile, doc/help.txt: Related to Vim's version8 documentation * doc/gui_x11.txt, doc/todo.txt, doc/vim.1, gvim.desktop, vim.desktop: Irrelevant to Neovim * doc/quickref.txt, doc/options.txt: As of yet unported 'emoji' * doc/tags, syntax/vim.vim: Generated at build time --- runtime/doc/eval.txt | 15 +++++++++++---- runtime/doc/help.txt | 2 +- runtime/doc/helphelp.txt | 6 +++++- runtime/doc/options.txt | 2 +- runtime/doc/pattern.txt | 6 +++--- runtime/doc/quickref.txt | 2 +- runtime/doc/repeat.txt | 50 ++++++++++++++++++++++++++++++++++++++---------- runtime/doc/starting.txt | 9 +++++---- runtime/doc/syntax.txt | 40 +++++++++++++++++++++----------------- runtime/doc/usr_41.txt | 5 ++++- 10 files changed, 93 insertions(+), 44 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 3495f9c004..0ca41370e9 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.4. Last change: 2016 Mar 29 +*eval.txt* For Vim version 7.4. Last change: 2016 Apr 12 VIM REFERENCE MANUAL by Bram Moolenaar @@ -413,7 +413,8 @@ only appear once. Examples: > A key is always a String. You can use a Number, it will be converted to a String automatically. Thus the String '4' and the number 4 will find the same entry. Note that the String '04' and the Number 04 are different, since the -Number will be converted to the String '4'. +Number will be converted to the String '4'. The empty string can be used as a +key. A value can be any expression. Using a Dictionary for a value creates a nested Dictionary: > @@ -861,11 +862,12 @@ These three can be repeated and mixed. Examples: expr8 *expr8* ----- expr8[expr1] item of String or |List| *expr-[]* *E111* + *subscript* If expr8 is a Number or String this results in a String that contains the expr1'th single byte from expr8. expr8 is used as a String, expr1 as a Number. This doesn't recognize multi-byte encodings, see |byteidx()| for -an alternative. +an alternative, or use `split()` to turn the string into a list of characters. Index zero gives the first byte. This is like it works in C. Careful: text column numbers start with one! Example, to get the byte under the @@ -2155,6 +2157,7 @@ writefile({list}, {fname} [, {flags}]) Number write list of lines to file {fname} xor({expr}, {expr}) Number bitwise XOR + abs({expr}) *abs()* Return the absolute value of {expr}. When {expr} evaluates to a |Float| abs() returns a |Float|. When {expr} can be @@ -2779,6 +2782,7 @@ cursor({list}) When there is one argument {list} this is used as a |List| with two, three or four item: + [{lnum}, {col}] [{lnum}, {col}, {off}] [{lnum}, {col}, {off}, {curswant}] This is like the return value of |getpos()| or |getcurpos()|, @@ -3207,7 +3211,10 @@ feedkeys({string} [, {mode}]) *feedkeys()* similar to using ":normal!". You can call feedkeys() several times without 'x' and then one time with 'x' (possibly with an empty {string}) to execute all the - typeahead. + typeahead. Note that when Vim ends in Insert mode it + will behave as if is typed, to avoid getting + stuck, waiting for a character to be typed before the + script continues. Return value is always 0. filereadable({file}) *filereadable()* diff --git a/runtime/doc/help.txt b/runtime/doc/help.txt index 305eaea924..fc4816a6c8 100644 --- a/runtime/doc/help.txt +++ b/runtime/doc/help.txt @@ -1,4 +1,4 @@ -*help.txt* For Vim version 7.4. Last change: 2016 Feb 27 +*help.txt* For Vim version 7.4. Last change: 2016 Mar 31 VIM - main help file k diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt index 9654f249fa..ca341af200 100644 --- a/runtime/doc/helphelp.txt +++ b/runtime/doc/helphelp.txt @@ -1,4 +1,4 @@ -*helphelp.txt* For Vim version 7.4. Last change: 2016 Mar 28 +*helphelp.txt* For Vim version 7.4. Last change: 2016 Apr 01 VIM REFERENCE MANUAL by Bram Moolenaar @@ -313,6 +313,10 @@ aligned on a line. When referring to an existing help tag and to create a hot-link, place the name between two bars (|) eg. |help-writing|. +When referring to a Vim command and to create a hot-link, place the +name between two backticks, eg. inside `:filetype`. You will see this is +highlighted as a command, like a code block (see below). + When referring to a Vim option in the help file, place the option name between two single quotes, eg. 'statusline' diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 669f74186c..e00f27f9f0 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 7.4. Last change: 2016 Mar 24 +*options.txt* For Vim version 7.4. Last change: 2016 Apr 12 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/pattern.txt b/runtime/doc/pattern.txt index 5897f756d8..0fe6106ec5 100644 --- a/runtime/doc/pattern.txt +++ b/runtime/doc/pattern.txt @@ -1,4 +1,4 @@ -*pattern.txt* For Vim version 7.4. Last change: 2016 Jan 03 +*pattern.txt* For Vim version 7.4. Last change: 2016 Apr 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1096,8 +1096,8 @@ x A single character, with no special meaning, matches itself '/', alphabetic, numeric, '_' or '~'. These items only work for 8-bit characters, except [:lower:] and [:upper:] also work for multi-byte characters when using the new - regexp engine. In the future these items may work for multi-byte - characters. + regexp engine. See |two-engines|. In the future these items may + work for multi-byte characters. */[[=* *[==]* - An equivalence class. This means that characters are matched that have almost the same meaning, e.g., when ignoring accents. This diff --git a/runtime/doc/quickref.txt b/runtime/doc/quickref.txt index b6ab33dd16..fcfecc02a1 100644 --- a/runtime/doc/quickref.txt +++ b/runtime/doc/quickref.txt @@ -1,4 +1,4 @@ -*quickref.txt* For Vim version 7.4. Last change: 2016 Feb 24 +*quickref.txt* For Vim version 7.4. Last change: 2016 Mar 30 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index 5a2396669e..e84bbe5439 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -1,4 +1,4 @@ -*repeat.txt* For Vim version 7.4. Last change: 2016 Mar 27 +*repeat.txt* For Vim version 7.4. Last change: 2016 Apr 05 VIM REFERENCE MANUAL by Bram Moolenaar @@ -70,8 +70,8 @@ examples. The global commands work by first scanning through the [range] lines and marking each line where a match occurs (for a multi-line pattern, only the start of the match matters). -In a second scan the [cmd] is executed for each marked line with its line -number prepended. For ":v" and ":g!" the command is executed for each not +In a second scan the [cmd] is executed for each marked line, as if the cursor +was in that line. For ":v" and ":g!" the command is executed for each not marked line. If a line is deleted its mark disappears. The default for [range] is the whole buffer (1,$). Use "CTRL-C" to interrupt the command. If an error message is given for a line, the command for that @@ -225,8 +225,11 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. there yet. Note that {name} is the directory name, not the name - of the .vim file. If the "{name}/plugin" directory - contains more than one file they are all sourced. + of the .vim file. All the files matching the pattern + pack/*/opt/{name}/plugin/**/*.vim ~ + will be sourced. This allows for using subdirectories + below "plugin", just like with plugins in + 'runtimepath'. If the filetype detection was not enabled yet (this is usually done with a "syntax enable" or "filetype @@ -242,15 +245,24 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|. Also see |pack-add|. *:packl* *:packloadall* -:packloadall[!] Load all packages in the "start" directories under - 'packpath'. The directories found are added to - 'runtimepath'. +:packl[oadall][!] Load all packages in the "start" directory under each + entry in 'packpath'. + + First all the directories found are added to + 'runtimepath', then the plugins found in the + directories are sourced. This allows for a plugin to + depend on something of another plugin, e.g. an + "autoload" directory. See |packload-two-steps| for + how this can be useful. + This is normally done automatically during startup, after loading your .vimrc file. With this command it can be done earlier. + Packages will be loaded only once. After this command it won't happen again. When the optional ! is added this command will load packages even when done before. + An error only causes sourcing the script where it happens to be aborted, further plugins will be loaded. See |packages|. @@ -456,8 +468,9 @@ You would now have these files under ~/.local/share/nvim/site: pack/foo/opt/foodebug/plugin/debugger.vim When Vim starts up, after processing your .vimrc, it scans all directories in -'packpath' for plugins under the "pack/*/start" directory and loads them. The -directory is added to 'runtimepath'. +'packpath' for plugins under the "pack/*/start" directory. First all those +directories are added to 'runtimepath'. Then all the plugins are loaded. +See |packload-two-steps| for how these two steps can be useful. In the example Vim will find "pack/foo/start/foobar/plugin/foo.vim" and adds "~/.local/share/nvim/site/pack/foo/start/foobar" to 'runtimepath'. @@ -585,6 +598,23 @@ the command after changing the plugin help: > :helptags path/start/foobar/doc :helptags path/opt/fooextra/doc + +Dependencies between plugins ~ + *packload-two-steps* +Suppose you have a two plugins that depend on the same functionality. You can +put the common functionality in an autoload directory, so that it will be +found automatically. Your package would have these files: + + pack/foo/start/one/plugin/one.vim > + call foolib#getit() +< pack/foo/start/two/plugin/two.vim > + call foolib#getit() +< pack/foo/start/lib/autoload/foolib.vim > + func foolib#getit() + +This works, because loading packages will first add all found directories to +'runtimepath' before sourcing the plugins. + ============================================================================== 7. Debugging scripts *debug-scripts* diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index 4829307706..236ed65f46 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 7.4. Last change: 2016 Mar 26 +*starting.txt* For Vim version 7.4. Last change: 2016 Apr 05 VIM REFERENCE MANUAL by Bram Moolenaar @@ -464,9 +464,10 @@ accordingly. Vim proceeds in this order: commands from the command line have not been executed yet. You can use "--cmd 'set noloadplugins'" |--cmd|. - Plugin packs are loaded. These are plugins, as above, but found in - 'packpath' "start" directories. Every plugin directory found is added - in 'runtimepath'. See |packages|. + Packages are loaded. These are plugins, as above, but found in the + "start" directory of each entry in 'packpath'. Every plugin directory + found is added in 'runtimepath' and then the plugins are sourced. See + |packages|. 7. Set 'shellpipe' and 'shellredir' The 'shellpipe' and 'shellredir' options are set according to the diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 9bec855190..491e5801c8 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 7.4. Last change: 2016 Mar 12 +*syntax.txt* For Vim version 7.4. Last change: 2016 Apr 10 VIM REFERENCE MANUAL by Bram Moolenaar @@ -936,26 +936,27 @@ To disable them use ":unlet". Example: > :unlet c_comment_strings Variable Highlight ~ -c_gnu GNU gcc specific items -c_comment_strings strings and numbers inside a comment -c_space_errors trailing white space and spaces before a -c_no_trail_space_error ... but no trailing spaces -c_no_tab_space_error ... but no spaces before a -c_no_bracket_error don't highlight {}; inside [] as errors -c_no_curly_error don't highlight {}; inside [] and () as errors; +*c_gnu* GNU gcc specific items +*c_comment_strings* strings and numbers inside a comment +*c_space_errors* trailing white space and spaces before a +*c_no_trail_space_error* ... but no trailing spaces +*c_no_tab_space_error* ... but no spaces before a +*c_no_bracket_error* don't highlight {}; inside [] as errors +*c_no_curly_error* don't highlight {}; inside [] and () as errors; except { and } in first column -c_curly_error highlight a missing }; this forces syncing from the +*c_curly_error* highlight a missing }; this forces syncing from the start of the file, can be slow -c_no_ansi don't do standard ANSI types and constants -c_ansi_typedefs ... but do standard ANSI types -c_ansi_constants ... but do standard ANSI constants -c_no_utf don't highlight \u and \U in strings -c_syntax_for_h for *.h files use C syntax instead of C++ and use objc +*c_no_ansi* don't do standard ANSI types and constants +*c_ansi_typedefs* ... but do standard ANSI types +*c_ansi_constants* ... but do standard ANSI constants +*c_no_utf* don't highlight \u and \U in strings +*c_syntax_for_h* for *.h files use C syntax instead of C++ and use objc syntax instead of objcpp -c_no_if0 don't highlight "#if 0" blocks as comments -c_no_cformat don't highlight %-formats in strings -c_no_c99 don't highlight C99 standard items -c_no_c11 don't highlight C11 standard items +*c_no_if0* don't highlight "#if 0" blocks as comments +*c_no_cformat* don't highlight %-formats in strings +*c_no_c99* don't highlight C99 standard items +*c_no_c11* don't highlight C11 standard items +*c_no_bsd* don't highlight BSD specific types When 'foldmethod' is set to "syntax" then /* */ comments and { } blocks will become a fold. If you don't want comments to become a fold use: > @@ -5026,6 +5027,9 @@ defaults back: > :syntax reset +It is a bit of a wrong name, since it does not reset any syntax items, it only +affects the highlighting. + This doesn't change the colors for the 'highlight' option. Note that the syntax colors that you set in your vimrc file will also be reset diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt index f00f03bae8..4d3ad49f1f 100644 --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -1,4 +1,4 @@ -*usr_41.txt* For Vim version 7.4. Last change: 2016 Mar 27 +*usr_41.txt* For Vim version 7.4. Last change: 2016 Apr 12 VIM USER MANUAL - by Bram Moolenaar @@ -768,6 +768,7 @@ Date and Time: *date-functions* *time-functions* strftime() convert time to a string reltime() get the current or elapsed time accurately reltimestr() convert reltime() result to a string + reltimefloat() convert reltime() result to a Float *buffer-functions* *window-functions* *arg-functions* Buffers, windows and the argument list: @@ -890,7 +891,9 @@ Mappings: *mapping-functions* Testing: *test-functions* assert_equal() assert that two expressions values are equal + assert_notequal() assert that two expressions values are not equal assert_match() assert that a pattern matches the value + assert_notmatch() assert that a pattern does not match the value assert_false() assert that an expression is false assert_true() assert that an expression is true assert_exception() assert that a command throws an exception -- cgit