feat(plugin): added support for virtual plugins. Closes #1836

This commit is contained in:
Folke Lemaitre 2024-12-06 20:28:50 +01:00
parent 3388a26417
commit ee64abc76b
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040
5 changed files with 14 additions and 5 deletions

View file

@ -270,7 +270,7 @@ function M.get_unloaded_rtp(modname, opts)
local Config = require("lazy.core.config")
if Config.spec then
for _, plugin in pairs(Config.spec.plugins) do
if not (plugin._.loaded or plugin.module == false) then
if not (plugin._.loaded or plugin.module == false or plugin.virtual) then
if norm == M.normname(plugin.name) then
table.insert(rtp, 1, plugin.dir)
else