patch 7.4.1553

Problem:    ":runtime" does not use 'packpath'.
Solution:   Add "what" argument.
This commit is contained in:
Bram Moolenaar
2016-03-12 22:47:14 +01:00
parent 7f8989dd8a
commit 8dcf259d90
5 changed files with 114 additions and 11 deletions

View File

@ -182,10 +182,12 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|.
{not in Vi}
*: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
@ -199,6 +201,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
@ -238,6 +249,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.
@ -461,8 +482,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 ~