mirror of
https://github.com/NotAShelf/neovim-flake.git
synced 2024-12-21 17:59:48 +01:00
adapt to flake-parts
This commit is contained in:
parent
f2151efd69
commit
1ba910f8de
1 changed files with 42 additions and 40 deletions
|
@ -1,45 +1,47 @@
|
||||||
# Home Manager module
|
# Home Manager module
|
||||||
{
|
{inputs, ...}: {
|
||||||
self,
|
perSystem = {
|
||||||
config,
|
system,
|
||||||
pkgs,
|
config,
|
||||||
lib ? pkgs.lib,
|
pkgs,
|
||||||
...
|
lib ? pkgs.lib,
|
||||||
}: let
|
...
|
||||||
cfg = config.programs.neovim-flake;
|
}:
|
||||||
set = self.packages.maximal {mainConfig = cfg.settings;};
|
with lib; let
|
||||||
in
|
cfg = config.programs.neovim-flake;
|
||||||
with lib; {
|
set = self'.packages.maximal {mainConfig = cfg.settings;};
|
||||||
meta.maintainers = [maintainers.notashelf];
|
in {
|
||||||
|
meta.maintainers = [maintainers.notashelf];
|
||||||
|
|
||||||
options.programs.neovim-flake = {
|
options.programs.neovim-flake = {
|
||||||
enable = mkEnableOption "A NeoVim IDE with a focus on configurability and extensibility.";
|
enable = mkEnableOption "A NeoVim IDE with a focus on configurability and extensibility.";
|
||||||
|
|
||||||
settings = mkOption {
|
settings = mkOption {
|
||||||
type = types.attrsOf types.anything;
|
type = types.attrsOf types.anything;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExpression ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
vim.viAlias = false;
|
vim.viAlias = false;
|
||||||
vim.vimAlias = true;
|
vim.vimAlias = true;
|
||||||
vim.lsp = {
|
vim.lsp = {
|
||||||
enable = true;
|
enable = true;
|
||||||
formatOnSave = true;
|
formatOnSave = true;
|
||||||
lightbulb.enable = true;
|
lightbulb.enable = true;
|
||||||
lspsaga.enable = false;
|
lspsaga.enable = false;
|
||||||
nvimCodeActionMenu.enable = true;
|
nvimCodeActionMenu.enable = true;
|
||||||
trouble.enable = true;
|
trouble.enable = true;
|
||||||
lspSignature.enable = true;
|
lspSignature.enable = true;
|
||||||
rust.enable = false;
|
rust.enable = false;
|
||||||
nix = true;
|
nix = true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
description = "Attribute set of neoflake preferences.";
|
description = "Attribute set of neoflake preferences.";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
home.packages = [set.neovim];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
}
|
||||||
config = mkIf cfg.enable {
|
|
||||||
home.packages = [set.neovim];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in a new issue