rust-tools keybindings

This commit is contained in:
krolyxon 2022-09-07 17:41:42 +05:30
parent e5d101c0b1
commit 2a093ca138
3 changed files with 18 additions and 7 deletions

View File

@ -23,13 +23,6 @@ M.general = {
},
}
M.bufferline = {
plugin = true,
n = {
["<S-Tab>" ] = {"<cmd> :BufferLineCycleNext <CR>"}
}
}
M.nvimtree = {
plugin = true,
@ -283,6 +276,18 @@ M.lspconfig = {
},
}
M.rust = {
plugin = true,
n = {
["<leader>rr"] = { "<cmd> RustRun <CR>", "RustRun"},
["<leader>rR"] = { "<cmd> RustRunnables <CR>", "RustRunnables"},
["<leader>rd"] = { "<cmd> RustDebuggables <CR>", "RustDebuggables"},
["<leader>rha"] = { "<cmd> RustHoverActions <CR>", "RustHoverActions"},
["<leader>roc"] = { "<cmd> RustOpenCargo <CR>", "RustOpenCargo"},
["<leader>rcg"] = { "<cmd> RustViewCrateGraph <CR>", "RustViewCrateGraph"},
},
}
M.blankline = {
plugin = true,

View File

@ -13,6 +13,11 @@ opt.title = true
opt.cmdheight = 1
opt.clipboard = "unnamedplus"
opt.cul = true -- cursor line
opt.mouse = opt.mouse + "nv" -- mouse scrolling
opt.ignorecase = true
opt.smartcase = true
opt.showmode = false
opt.incsearch = true
-- numbers
opt.number = true

View File

@ -66,6 +66,7 @@ local plugins = {
after = "nvim-lspconfig",
config = function ()
require("plugins.configs.rust-tools")
require("core.utils").load_mappings "rust"
require("core.utils").load_mappings "lspconfig"
end,
},