refactor: renamed plugins_local to dev

This commit is contained in:
Folke Lemaitre 2022-11-30 23:08:00 +01:00
parent 47f5c124aa
commit 5d81c5062b
No known key found for this signature in database
GPG Key ID: 41F8B1FBACAE2040
2 changed files with 5 additions and 5 deletions

View File

@ -6,10 +6,10 @@ local M = {}
M.defaults = { M.defaults = {
opt = true, opt = true,
plugins = "config.plugins", plugins = "config.plugins",
plugins_local = { dev = {
path = vim.fn.expand("~/projects"), path = vim.fn.expand("~/projects"), -- the path where you store your projects
---@type string[] ---@type string[]
patterns = {}, patterns = {}, -- For example {"folke"}
}, },
packpath = vim.fn.stdpath("data") .. "/site/pack/lazy", packpath = vim.fn.stdpath("data") .. "/site/pack/lazy",
lockfile = vim.fn.stdpath("config") .. "/lazy-lock.json", lockfile = vim.fn.stdpath("config") .. "/lazy-lock.json",

View File

@ -86,9 +86,9 @@ function Spec:add(plugin, is_dep)
plugin.dep = is_dep plugin.dep = is_dep
-- check for plugins that should be local -- check for plugins that should be local
for _, pattern in ipairs(Config.options.plugins_local.patterns) do for _, pattern in ipairs(Config.options.dev.patterns) do
if plugin[1]:find(pattern, 1, true) then if plugin[1]:find(pattern, 1, true) then
plugin.uri = Config.options.plugins_local.path .. "/" .. plugin.name plugin.uri = Config.options.dev.path .. "/" .. plugin.name
break break
end end
end end