mirror of
				https://github.com/folke/lazy.nvim.git
				synced 2025-10-31 22:41:05 +00:00 
			
		
		
		
	fix: set correct dir for lazy plugin
This commit is contained in:
		
					parent
					
						
							
								2d6559302e
							
						
					
				
			
			
				commit
				
					
						23984dd1f3
					
				
			
		
					 2 changed files with 7 additions and 4 deletions
				
			
		|  | @ -101,6 +101,9 @@ M.to_clean = {} | ||||||
| ---@type LazyConfig | ---@type LazyConfig | ||||||
| M.options = {} | M.options = {} | ||||||
| 
 | 
 | ||||||
|  | ---@type string | ||||||
|  | M.me = nil | ||||||
|  | 
 | ||||||
| ---@param spec LazySpec | ---@param spec LazySpec | ||||||
| ---@param opts? LazyConfig | ---@param opts? LazyConfig | ||||||
| function M.setup(spec, opts) | function M.setup(spec, opts) | ||||||
|  | @ -113,10 +116,10 @@ function M.setup(spec, opts) | ||||||
|     vim.go.packpath = "" |     vim.go.packpath = "" | ||||||
|   end |   end | ||||||
|   if M.options.performance.rtp.reset then |   if M.options.performance.rtp.reset then | ||||||
|     local me = debug.getinfo(1, "S").source:sub(2) |     M.me = debug.getinfo(1, "S").source:sub(2) | ||||||
|     me = vim.fn.fnamemodify(me, ":p:h:h:h:h") |     M.me = vim.fn.fnamemodify(M.me, ":p:h:h:h:h") | ||||||
|     vim.opt.rtp = { |     vim.opt.rtp = { | ||||||
|       me, |       M.me, | ||||||
|       vim.env.VIMRUNTIME, |       vim.env.VIMRUNTIME, | ||||||
|       vim.fn.stdpath("config"), |       vim.fn.stdpath("config"), | ||||||
|       vim.fn.stdpath("config") .. "/after", |       vim.fn.stdpath("config") .. "/after", | ||||||
|  |  | ||||||
|  | @ -239,7 +239,7 @@ function M.load() | ||||||
| 
 | 
 | ||||||
|   -- add ourselves |   -- add ourselves | ||||||
|   spec.plugins["lazy.nvim"] = nil |   spec.plugins["lazy.nvim"] = nil | ||||||
|   spec:add({ "folke/lazy.nvim", lazy = true, dev = false }) |   spec:add({ "folke/lazy.nvim", lazy = true, dir = Config.me }) | ||||||
| 
 | 
 | ||||||
|   local existing = Config.plugins |   local existing = Config.plugins | ||||||
|   Config.plugins = spec.plugins |   Config.plugins = spec.plugins | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue