0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

patch 8.0.0612: pack dirs are added to 'runtimepath' too late

Problem:    Package directories are added to 'runtimepath' only after loading
            non-package plugins.
Solution:   Split off the code to add package directories to 'runtimepath'.
            (Ingo Karkat, closes #1680)
This commit is contained in:
Bram Moolenaar
2017-06-04 17:47:42 +02:00
parent 976787d1f3
commit ce876aaa9a
6 changed files with 71 additions and 10 deletions

View File

@@ -449,6 +449,12 @@ vim_main2(void)
*/
if (p_lpl)
{
/* First add all package directories to 'runtimepath', so that their
* autoload directories can be found. Only if not done already with a
* :packloadall command. */
if (!did_source_packages)
add_pack_start_dirs();
# ifdef VMS /* Somehow VMS doesn't handle the "**". */
source_runtime((char_u *)"plugin/*.vim", DIP_ALL | DIP_NOAFTER);
# else
@@ -456,7 +462,10 @@ vim_main2(void)
# endif
TIME_MSG("loading plugins");
ex_packloadall(NULL);
/* Only source "start" packages if not done already with a :packloadall
* command. */
if (!did_source_packages)
load_start_packages();
TIME_MSG("loading packages");
# ifdef VMS /* Somehow VMS doesn't handle the "**". */