[nvim] Call addGitTopLevelDirectoryToRuntimePath after sourcing common vimrc
This commit is contained in:
parent
0a3dd9451a
commit
202dfdb886
1 changed files with 4 additions and 2 deletions
|
|
@ -14,6 +14,8 @@ function gitTopLevelDirectory()
|
||||||
return gitRepoTopLevelDirectoryPath
|
return gitRepoTopLevelDirectoryPath
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Enable per-project (per-git repository) customization of (neo)vim by looking
|
||||||
|
-- for .vim and .nvim directories in the root of the git repository.
|
||||||
function addGitTopLevelDirectoryToRuntimePath()
|
function addGitTopLevelDirectoryToRuntimePath()
|
||||||
local gitTopLevelPath = gitTopLevelDirectory()
|
local gitTopLevelPath = gitTopLevelDirectory()
|
||||||
if gitTopLevelPath == nil or string.len(gitTopLevelPath) == 0 then
|
if gitTopLevelPath == nil or string.len(gitTopLevelPath) == 0 then
|
||||||
|
|
@ -39,13 +41,13 @@ function addGitTopLevelDirectoryToRuntimePath()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
addGitTopLevelDirectoryToRuntimePath()
|
|
||||||
|
|
||||||
vim.cmd [[
|
vim.cmd [[
|
||||||
source ~/.vimrc.common
|
source ~/.vimrc.common
|
||||||
source ~/.vim/plugins.vim
|
source ~/.vim/plugins.vim
|
||||||
]]
|
]]
|
||||||
|
|
||||||
|
addGitTopLevelDirectoryToRuntimePath()
|
||||||
|
|
||||||
require 'autocommands'
|
require 'autocommands'
|
||||||
require 'colors'
|
require 'colors'
|
||||||
require 'configuration'
|
require 'configuration'
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue