fix: add trouble and formatter nvim plugins
Signed-off-by: Lucas Sta Maria <lucas@priime.dev>
This commit is contained in:
parent
ded04456cb
commit
6db99389bc
4 changed files with 12 additions and 8 deletions
|
@ -7,8 +7,6 @@ local function map(mode, lhs, rhs, opts)
|
|||
vim.api.nvim_set_keymap(mode, lhs, rhs, options)
|
||||
end
|
||||
|
||||
require("nvim-autopairs").setup {}
|
||||
|
||||
map("i", "<C-c>", "<ESC>:w<CR>:!just<CR>")
|
||||
map("n", "<C-c>", "<ESC>:w<CR>:!just<CR>")
|
||||
|
||||
|
|
|
@ -30,7 +30,6 @@ cmp.setup({
|
|||
{ name = 'nvim_lsp' },
|
||||
{ name = 'ultisnips' }, -- For ultisnips users.
|
||||
}, {
|
||||
{ name = 'buffer' },
|
||||
})
|
||||
})
|
||||
|
||||
|
@ -151,9 +150,6 @@ lspconfig.java_language_server.setup {
|
|||
lspconfig.racket_langserver.setup {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
root_dir = lspconfig.util.root_pattern(
|
||||
'main.rkt'
|
||||
)
|
||||
}
|
||||
|
||||
lspconfig.ocamllsp.setup {
|
||||
|
@ -161,7 +157,7 @@ lspconfig.ocamllsp.setup {
|
|||
capabilities = capabilities,
|
||||
}
|
||||
|
||||
lspconfig.pylsp.setup {
|
||||
lspconfig.jedi_language_server.setup {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ local function map(mode, lhs, rhs, opts)
|
|||
end
|
||||
|
||||
-- format
|
||||
map('n', '<leader>f', ':Format<CR>')
|
||||
map('n', '<leader>f', ':w<CR>:Format<CR>')
|
||||
|
||||
-- open terminal
|
||||
map("n", "<leader>ott", ":ToggleTerm<CR>")
|
||||
|
@ -56,3 +56,6 @@ map("n", "<C-k>", ":BufferLineCycleNext<CR>")
|
|||
map("n", "<C-j>", ":BufferLineCyclePrev<CR>")
|
||||
map("n", "<C-S-k>", ":BufferLineMoveNext<CR>")
|
||||
map("n", "<C-S-j>", ":BufferLineMovePrev<CR>")
|
||||
|
||||
-- trouble
|
||||
map("n", "<leader>od", ":TroubleToggle<CR>")
|
||||
|
|
|
@ -32,6 +32,7 @@ packer.startup(function()
|
|||
use("simrat39/symbols-outline.nvim")
|
||||
use("lcheylus/overlength.nvim")
|
||||
use("akinsho/bufferline.nvim")
|
||||
use("folke/trouble.nvim")
|
||||
|
||||
-- completion
|
||||
use("hrsh7th/cmp-nvim-lsp")
|
||||
|
@ -178,6 +179,9 @@ require('formatter').setup {
|
|||
}
|
||||
end
|
||||
},
|
||||
c = {
|
||||
require('formatter.filetypes.c').clangformat
|
||||
},
|
||||
cpp = {
|
||||
require('formatter.filetypes.cpp').clangformat
|
||||
},
|
||||
|
@ -213,3 +217,6 @@ require('Comment').setup {}
|
|||
require("nvim-autopairs").setup {
|
||||
disable_filetype = { "TelescopePrompt", "racket" }
|
||||
}
|
||||
|
||||
-- trouple
|
||||
require("trouble").setup {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue