feat(nvim): move coc config to hm config

This commit is contained in:
matt1432 2023-09-19 12:54:00 -04:00
parent 34d1e0ee47
commit df044b0583

View file

@ -16,31 +16,6 @@ let
# always installs latest version # always installs latest version
plugin = pluginGit "HEAD"; plugin = pluginGit "HEAD";
in { in {
xdg.configFile = {
"nvim/coc-settings.json".source = pkgs.writeText "coc-settings.json" ''
{
"colors.enable": true,
"coc.preferences.formatOnType": true,
"Lua.misc.parameters": [
"--metapath",
"~/.cache/sumneko_lua/meta",
"--logpath",
"~/.cache/sumneko_lua/log"
],
"sumneko-lua.serverDir": "${pkgs.lua-language-server}/share/lua-language-server",
"java.jdt.ls.java.home": "${pkgs.temurin-bin-18}",
"bashIde.shellcheckPath": "${pkgs.shellcheck}/bin/shellcheck",
"languageserver": {
"nix": {
"command": "nil",
"filetypes": ["nix"],
"rootPatterns": ["flake.nix"],
}
}
}
'';
};
programs.neovim = { programs.neovim = {
enable = true; enable = true;
package = pkgs.neovim-nightly; package = pkgs.neovim-nightly;
@ -67,10 +42,33 @@ in {
python311Packages.pylint python311Packages.pylint
nil nil
]; ];
coc = {
enable = true;
settings = {
"colors.enable" = true;
"coc.preferences.formatOnType" = true;
"Lua.misc.parameters" = [
"--metapath"
"~/.cache/sumneko_lua/meta"
"--logpath"
"~/.cache/sumneko_lua/log"
];
"sumneko-lua.serverDir" = "${pkgs.lua-language-server}/share/lua-language-server";
"java.jdt.ls.java.home" = "${pkgs.temurin-bin-18}";
"bashIde.shellcheckPath" = "${pkgs.shellcheck}/bin/shellcheck";
languageserver = {
nix = {
command = "nil";
filetypes = [ "nix" ];
rootPatterns = [ "flake.nix" ];
};
};
};
};
plugins = with pkgs.vimPlugins; [ plugins = with pkgs.vimPlugins; [
vim-which-key vim-which-key
coc-nvim
coc-java coc-java
coc-css coc-css
coc-sumneko-lua coc-sumneko-lua
@ -91,6 +89,7 @@ in {
nvim-treesitter.withAllGrammars nvim-treesitter.withAllGrammars
nvim-treesitter nvim-treesitter
nvim-autopairs
(plugin "Mofiqul/dracula.nvim") (plugin "Mofiqul/dracula.nvim")
(plugin "lukas-reineke/indent-blankline.nvim") (plugin "lukas-reineke/indent-blankline.nvim")
@ -104,7 +103,6 @@ in {
(plugin "MunifTanjim/nui.nvim") (plugin "MunifTanjim/nui.nvim")
# to explore more # to explore more
nvim-autopairs
(plugin "sindrets/diffview.nvim") (plugin "sindrets/diffview.nvim")
(plugin "folke/todo-comments.nvim") (plugin "folke/todo-comments.nvim")
(plugin "petertriho/nvim-scrollbar") (plugin "petertriho/nvim-scrollbar")