mirror of
https://github.com/zoriya/lz.n.git
synced 2025-12-06 06:36:11 +00:00
docs(readme): add nixvim example (#123)
This commit is contained in:
88
README.md
88
README.md
@@ -285,38 +285,68 @@ require("lz.n").load {
|
|||||||
|
|
||||||
<details>
|
<details>
|
||||||
<summary>
|
<summary>
|
||||||
<b><a href="https://wiki.nixos.org/wiki/Neovim">Nix (Home Manager) example</a></b>
|
<b><a href="https://wiki.nixos.org/wiki/Neovim">Nix (Home Manager)</a> example</b>
|
||||||
</summary>
|
</summary>
|
||||||
|
|
||||||
```nix
|
```nix
|
||||||
programs.neovim = {
|
{
|
||||||
enable = true;
|
programs.neovim = {
|
||||||
plugins = with pkgs.vimPlugins [
|
enable = true;
|
||||||
lz-n
|
plugins = with pkgs.vimPlugins [
|
||||||
{
|
lz-n
|
||||||
plugin = pkgs.vimPlugins.telescope-nvim;
|
{
|
||||||
config = ''
|
plugin = pkgs.vimPlugins.telescope-nvim;
|
||||||
require("lz.n").load {
|
config = ''
|
||||||
"telescope.nvim",
|
require("lz.n").load {
|
||||||
cmd = "Telescope",
|
"telescope.nvim",
|
||||||
}
|
cmd = "Telescope",
|
||||||
'';
|
}
|
||||||
type = "lua";
|
'';
|
||||||
optional = true;
|
type = "lua";
|
||||||
}
|
optional = true;
|
||||||
{
|
}
|
||||||
plugin = pkgs.vimPlugins.sweetie-nvim;
|
{
|
||||||
config = ''
|
plugin = pkgs.vimPlugins.sweetie-nvim;
|
||||||
require("lz.n").load {
|
config = ''
|
||||||
"sweetie.nvim",
|
require("lz.n").load {
|
||||||
colorscheme = "sweetie",
|
"sweetie.nvim",
|
||||||
}
|
colorscheme = "sweetie",
|
||||||
'';
|
}
|
||||||
type = "lua";
|
'';
|
||||||
optional = true;
|
type = "lua";
|
||||||
}
|
optional = true;
|
||||||
];
|
}
|
||||||
};
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>
|
||||||
|
<b><a href="https://wiki.nixos.org/wiki/Neovim">Nix (NixVim)</a> example</b>
|
||||||
|
</summary>
|
||||||
|
|
||||||
|
> You can find up-to-date NixVim documentation for lazy-loading with `lz.n` here:
|
||||||
|
>
|
||||||
|
> https://nix-community.github.io/nixvim/user-guide/lazy-loading
|
||||||
|
|
||||||
|
```nix
|
||||||
|
{
|
||||||
|
# Enable lz.n as lazy-loading provider
|
||||||
|
plugins.lz-n.enable = true;
|
||||||
|
|
||||||
|
plugins.telescope = {
|
||||||
|
enable = true;
|
||||||
|
lazyLoad.settings.cmd = "Telescope";
|
||||||
|
};
|
||||||
|
|
||||||
|
colorschemes.catppuccin = {
|
||||||
|
enable = true;
|
||||||
|
lazyLoad.settings.colorscheme = "catppuccin";
|
||||||
|
};
|
||||||
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|||||||
Reference in New Issue
Block a user