2022-06-29 00:02:00 +02:00
|
|
|
{ lib, pkgs, config, ... }@inputs:
|
|
|
|
with lib;
|
|
|
|
let
|
|
|
|
cfg = config.mae.nvim;
|
|
|
|
in
|
|
|
|
{
|
|
|
|
imports = [
|
2022-08-17 22:02:19 +02:00
|
|
|
./nvim-lsp.nix
|
2022-08-17 01:26:57 +02:00
|
|
|
./js.nix
|
2022-08-26 22:55:16 +02:00
|
|
|
./go.nix
|
2022-06-29 00:02:00 +02:00
|
|
|
./rust.nix
|
2022-08-17 22:02:19 +02:00
|
|
|
./nix.nix
|
2022-09-03 18:00:46 +02:00
|
|
|
./python.nix
|
2022-08-28 01:03:01 +02:00
|
|
|
./clangd.nix
|
2022-06-29 00:02:00 +02:00
|
|
|
];
|
2022-08-17 22:02:19 +02:00
|
|
|
|
2022-06-29 00:02:00 +02:00
|
|
|
options.mae.nvim = {
|
|
|
|
enable = mkEnableOption "enable neovim";
|
|
|
|
};
|
|
|
|
config = {
|
2022-09-19 15:51:26 +02:00
|
|
|
home.sessionVariables.EDITOR = "${pkgs.neovim}/bin/nvim";
|
2022-06-29 00:02:00 +02:00
|
|
|
programs.neovim = mkIf cfg.enable {
|
|
|
|
enable = true;
|
|
|
|
vimdiffAlias = true;
|
|
|
|
plugins = with pkgs.vimPlugins; [
|
|
|
|
neoformat
|
|
|
|
undotree
|
|
|
|
|
|
|
|
fzf-vim
|
|
|
|
{
|
|
|
|
plugin = iceberg-vim;
|
|
|
|
config = "colorscheme iceberg";
|
|
|
|
}
|
|
|
|
vim-sleuth
|
|
|
|
];
|
2022-08-26 22:55:16 +02:00
|
|
|
extraPackages = with pkgs; [
|
|
|
|
nodePackages.prettier
|
|
|
|
];
|
2022-06-29 00:02:00 +02:00
|
|
|
extraConfig = ''
|
|
|
|
set background=dark
|
|
|
|
set termguicolors
|
|
|
|
|
|
|
|
set ic
|
|
|
|
set number
|
|
|
|
set autoindent
|
|
|
|
|
|
|
|
set shortmess+=c
|
2022-08-17 22:02:19 +02:00
|
|
|
set completeopt=menuone,noinsert,noselect
|
2022-06-29 00:02:00 +02:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|