Add c++ lsp
This commit is contained in:
4
init.lua
4
init.lua
@@ -172,6 +172,8 @@ vim.api.nvim_create_autocmd("BufWritePre", {
|
||||
require("go").setup{}
|
||||
require("lspconfig").gopls.setup{}
|
||||
|
||||
require("lspconfig").ccls.setup{}
|
||||
|
||||
|
||||
-- Global mappings.
|
||||
-- See `:help vim.diagnostic.*` for documentation on any of the below functions
|
||||
@@ -240,6 +242,7 @@ set.ignorecase = true
|
||||
set.smartcase = true
|
||||
-- avoid frustrations
|
||||
set.autoread = true
|
||||
set.scrolloff = 6
|
||||
-- autoindent works weirdly sometimes
|
||||
-- set.autoindent = true
|
||||
vim.keymap.set("n", "gtl", ":tabn<cr>")
|
||||
@@ -252,6 +255,7 @@ vim.keymap.set("n", "gtH", ":execute 'silent! tabmove ' . (tabpagenr()-2)<cr>")
|
||||
vim.keymap.set("n", "gtn", ":tabedit<cr>")
|
||||
-- previous tab
|
||||
vim.keymap.set("n", "gb", ":bprevious<cr>")
|
||||
vim.keymap.set("n", "gn", ":bnext<cr>")
|
||||
-- switch windows using g<movement> rather than <C-W><movement>
|
||||
vim.keymap.set("n", "gwh", "<C-W>h")
|
||||
vim.keymap.set("n", "gwl", "<C-W>l")
|
||||
|
||||
Reference in New Issue
Block a user