kjuulh
d80976a36b
Add .config/nvim/README.md Add .config/nvim/.gitignore Add .config/nvim/.neoconf.json Add .config/nvim/init.lua Add .config/nvim/lazy-lock.json Add .config/nvim/lua/config/autocmds.lua Add .config/nvim/lua/config/keymaps.lua Add .config/nvim/lua/config/lazy.lua Add .config/nvim/lua/config/options.lua Add .config/nvim/lua/plugins/catppuccin.lua Add .config/nvim/lua/plugins/copilot-cmp.lua Add .config/nvim/lua/plugins/copilot.lua Add .config/nvim/lua/plugins/core.lua Add .config/nvim/lua/plugins/crates.lua Add .config/nvim/lua/plugins/example.lua Add .config/nvim/lua/plugins/lspconfig.lua Add .config/nvim/lua/plugins/neoconf.lua Add .config/nvim/lua/plugins/neorg.lua Add .config/nvim/lua/plugins/noice.lua Add .config/nvim/lua/plugins/null-ls.lua Add .config/nvim/lua/plugins/nvim-cmp.lua Add .config/nvim/lua/plugins/nvim-dap.lua Add .config/nvim/lua/plugins/ranger.lua Add .config/nvim/lua/plugins/rust-tools.lua Add .config/nvim/lua/plugins/tmux.lua Add .config/nvim/lua/plugins/toggleterm.lua Add .config/nvim/lua/plugins/treesitter.lua Add .config/nvim/lua/plugins/vim-wordmotion.lua Add .config/nvim/lua/plugins/zen-mode.lua Add .config/nvim/neoconf.json Add .config/nvim/queries/hurl/highlights.scm Add .config/nvim/queries/hurl/injections.scm Add .config/nvim/stylua.toml Add .config/ranger/.keep Add .config/toot/config.json Add .config/zathura/.keep Add .config/zellij/config.kdl Update .zimrc
41 lines
1022 B
Lua
41 lines
1022 B
Lua
return {
|
|
"simrat39/rust-tools.nvim",
|
|
config = function()
|
|
local rt = require("rust-tools")
|
|
|
|
rt.setup({
|
|
server = {
|
|
on_attach = function(_, bufnr)
|
|
-- Hover actions
|
|
vim.keymap.set("n", "<C-space>", rt.hover_actions.hover_actions, { buffer = bufnr })
|
|
-- Code action groups
|
|
vim.keymap.set("n", "<Leader>a", rt.code_action_group.code_action_group, { buffer = bufnr })
|
|
end,
|
|
settings = {
|
|
["rust-analyzer"] = {
|
|
imports = {
|
|
granularity = {
|
|
group = "module",
|
|
},
|
|
prefix = "self",
|
|
},
|
|
cargo = {
|
|
allFeatures = true,
|
|
buildScripts = {
|
|
enable = true,
|
|
},
|
|
procMacro = {
|
|
enable = true,
|
|
}
|
|
},
|
|
checkOnSave = {
|
|
allFeatures = true,
|
|
enable = true
|
|
}
|
|
},
|
|
},
|
|
},
|
|
})
|
|
end,
|
|
}
|