Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable Lazy option pkg.enabled with mkDefault false? #14

Open
nekowinston opened this issue Oct 19, 2024 · 2 comments
Open

Disable Lazy option pkg.enabled with mkDefault false? #14

nekowinston opened this issue Oct 19, 2024 · 2 comments

Comments

@nekowinston
Copy link
Contributor

I just updated my plugins, and it seems that this option being enabled (the default) allows plugins to pull in their own dependencies. While this is a nice feature for Lazy, it's also impure.
In my case, noice.nvim is just named noice in my config, so some other plugin tried to pull noice.nvim again to satisfy its dependency.

I see there's also rockspec support in Lazy now, and those dependencies are also part of packspec? Dunno if there's anything specific to disable to prevent that from causing an impurity.

nekowinston added a commit to nekowinston/neovim.drv that referenced this issue Oct 19, 2024
turning off lazy `pkg.enabled` to work around impurity

refs: willruggiano/neovim.nix#14
@willruggiano
Copy link
Owner

Sorry, I'm not entirely sure what exactly you're referencing. Is this a nix thing, neovim.nix thing or lazy.nvim thing?

@nekowinston
Copy link
Contributor Author

A lazy.nvim default setting: https://github.com/folke/lazy.nvim/blob/1159bdccd8910a0fd0914b24d6c3d186689023d9/doc/lazy.nvim.txt#L67-L68
& i'd propose changing the default here, just like disabling install.missing:

settings = mkOption {
type = submodule {
freeformType = attrsOf anything;
options = {
dev = {
path = mkOption {
type = nullOr (oneOf [path str]);
default = null;
};
};
install = {
missing = mkOption {
type = bool;
default = false;
};
};
};
};
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants