wip: feat(nvim/rust-tools): begin migration

This commit is contained in:
u2515h
2023-12-27 09:31:44 +01:00
parent cdb1cbd040
commit ab788929d9
4 changed files with 253 additions and 19 deletions

View File

@@ -45,7 +45,6 @@ in
fzf-vim
coc-sh
coc-nvim
coc-rust-analyzer
coc-json
coc-yaml
coc-tsserver
@@ -63,6 +62,7 @@ in
nvim-dap-ui
nvim-notify
rust-tools-nvim
plenary-nvim
crates-nvim
nvim-lspconfig
telescope-nvim
@@ -76,11 +76,19 @@ in
lldb = pkgs.lldb;
rust_analyzer = rust-analyzer;
};
pathsLua = pkgs.writeTextFile {
name = "nvim-deps.lua";
text = ''
return {
${concatStringsSep ",\n " (mapAttrsToList (name: path: ''${name}_path = "${path}"'') paths)}
}
'';
};
confDir = lib.sourceFilesBySuffices ./. [ "lua" "vim" ];
in
with lib; ''
vim.cmd [[source ${confDir}/init.vim]]
${concatStringsSep "\n" (mapAttrsToList (name: path: ''${name}_path = "${path}"'') paths)}
package.path = package.path .. ";${confDir}/?.lua;${pathsLua};"
dofile("${confDir}/init.lua")
'';
};
@@ -186,9 +194,9 @@ in
sdk = [ rust-sdk ];
};
imports.group.enable = true;
# inlayHints = {
# closureReturnTypeHints.enable = false;
# };
inlayHints = {
closureReturnTypeHints.enable = false;
};
highlightRelated = {
yieldPoints.enable = true;
references.enable = true;