From 202dfdb886ab22608056b451df5489c6b79f874c Mon Sep 17 00:00:00 2001 From: Eryn Wells Date: Wed, 9 Oct 2024 09:50:05 -0700 Subject: [PATCH] [nvim] Call addGitTopLevelDirectoryToRuntimePath after sourcing common vimrc --- config/nvim/init.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/config/nvim/init.lua b/config/nvim/init.lua index 6830c07..db2bb03 100644 --- a/config/nvim/init.lua +++ b/config/nvim/init.lua @@ -14,6 +14,8 @@ function gitTopLevelDirectory() return gitRepoTopLevelDirectoryPath 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() local gitTopLevelPath = gitTopLevelDirectory() if gitTopLevelPath == nil or string.len(gitTopLevelPath) == 0 then @@ -39,13 +41,13 @@ function addGitTopLevelDirectoryToRuntimePath() end end -addGitTopLevelDirectoryToRuntimePath() - vim.cmd [[ source ~/.vimrc.common source ~/.vim/plugins.vim ]] +addGitTopLevelDirectoryToRuntimePath() + require 'autocommands' require 'colors' require 'configuration'