fix(pack): move plugins out from lua runtime path

This commit is contained in:
2026-04-15 05:07:29 +02:00
parent 0211ed53a1
commit 1293be93aa
16 changed files with 6 additions and 6 deletions
+6 -6
View File
@@ -34,12 +34,12 @@ end
---@param name string
---@return string?
local function normalize_name(name)
name = name:match("[^.]+")
if name then
return name:lower()
end
name = name:gsub("%.lua$", "")
name = name:gsub("%.nvim$", "")
if name == "" then
return nil
end
return name:lower()
end
---@param plugin ow.Pack.Plugin
@@ -49,7 +49,7 @@ local function load(plugin)
log.error("Invalid plugin name: %s", plugin.name)
return
end
local path = string.format("%s/lua/plugins/%s.lua", config_dir, name)
local path = vim.fs.joinpath(config_dir, "plugins", name .. ".lua")
if vim.uv.fs_stat(path) then
local ok, err = exec(path)