dotfiles/modules/programs/nvim/default.nix

56 lines
1.1 KiB
Nix
Raw Normal View History

2023-09-10 13:30:29 +02:00
{ config, lib, pkgs, ... }:
2022-07-15 13:11:54 +02:00
with lib;
let
cfg = config.my.programs.nvim;
2022-07-15 13:11:54 +02:00
in
{
2023-09-10 13:30:29 +02:00
imports = lib.my.listModulesRec ./plugins;
2023-06-10 21:52:57 +02:00
2023-09-17 09:35:10 +02:00
options.my.programs.nvim.enable = mkEnableOption "nvim";
2022-07-15 13:11:54 +02:00
config = mkIf cfg.enable {
2023-03-02 09:13:46 +01:00
home-manager.users.moritz = {
home.packages = with pkgs; [
(
if config.my.programs.hyprland.enable
then neovide-hyprland
else neovide
)
2023-02-16 18:03:55 +01:00
];
2023-09-10 13:30:29 +02:00
2023-03-02 09:13:46 +01:00
programs.neovim = {
enable = true;
package = pkgs.neovim-nightly;
vimAlias = true;
vimdiffAlias = true;
withNodeJs = true;
withPython3 = true;
2023-07-24 18:44:03 +02:00
extraPackages = with pkgs;
[
alejandra
black
deadnix
isort
jq
nil
nixpkgs-fmt
nodePackages.bash-language-server
rustfmt
shellcheck
shfmt
statix
stylua
sumneko-lua-language-server
taplo
typst
typst-lsp
yamlfmt
];
2023-09-17 09:35:10 +02:00
extraLuaConfig = readFile ./options.lua;
lazy.enable = true;
2023-03-02 09:13:46 +01:00
};
2022-07-15 13:11:54 +02:00
};
};
}