nixos/modules/dev/editors/nvim/default.nix

66 lines
1.6 KiB
Nix
Raw Normal View History

{ inputs, options, config, lib, pkgs, ... }:
2024-08-01 16:24:09 +04:00
let
2024-12-26 02:40:19 +04:00
sources = import ./sources.nix { inherit pkgs; };
2023-08-11 00:30:24 +04:00
cfg = config.modules.dev.editors.nvim;
in {
2024-12-26 02:40:19 +04:00
imports = [ inputs.nvf.nixosModules.default ];
options.modules.dev.editors.nvim = { enable = lib.mkEnableOption false; };
2023-07-09 02:15:18 +04:00
2024-08-01 16:24:09 +04:00
config = lib.mkIf cfg.enable {
2023-08-11 00:30:24 +04:00
# because yes
2024-12-26 02:40:19 +04:00
# users.users.sako.packages = with pkgs; [
# # flakes
# direnv
# # vscode like git
# # lazygit
# ];
programs.nvf = {
enable = true;
2024-12-26 15:53:00 +04:00
enableManpages = true;
2024-12-26 02:40:19 +04:00
settings = {
# vim.lazy = {
# };
vim = {
lsp = { enable = true; };
2024-12-26 16:10:25 +04:00
filetree.nvimTree.enable = true;
2024-12-26 18:07:51 +04:00
precense.neocord = {
enable = true;
setupOpts = {
workspace_text = "Working on something";
};
};
2024-12-26 15:26:20 +04:00
languages = {
enableLSP = true;
2024-12-26 16:10:25 +04:00
clang.enable = true;
2024-12-26 18:08:16 +04:00
python = {
enable = true;
2024-12-26 18:09:38 +04:00
format.enable = true;
2024-12-26 18:08:16 +04:00
};
2024-12-26 15:26:20 +04:00
nix = {
enable = true;
format.enable = true;
};
};
2024-12-26 02:40:19 +04:00
utility = { vim-wakatime.enable = true; };
2024-12-26 15:53:00 +04:00
extraPlugins = {
"kanagawa.nvim" = {
package = sources."kanagawa.nvim";
setup = ''
require('kanagawa').setup({ theme = 'dragon'})
vim.cmd('colorscheme kanagawa')
'';
};
};
2024-12-26 02:40:19 +04:00
};
};
};
# home-manager.users.sako.xdg.configFile.nvim = {
# source = ../../../../config/nvim;
# recursive = true;
# };
2023-07-09 02:15:18 +04:00
};
}