shorten lsp.buf commands from LspBuf.. to Lb
This commit is contained in:
parent
23662ac758
commit
12c58d90fb
|
|
@ -43,7 +43,7 @@ end
|
||||||
|
|
||||||
for func_name, _ in pairs(lsp_buf) do
|
for func_name, _ in pairs(lsp_buf) do
|
||||||
if type(lsp_buf[func_name]) == "function" then -- Check if the value is a function
|
if type(lsp_buf[func_name]) == "function" then -- Check if the value is a function
|
||||||
local command_name = 'LspBuf' .. snake_to_pascal(func_name)
|
local command_name = 'Lb' .. snake_to_pascal(func_name)
|
||||||
vim.api.nvim_create_user_command(
|
vim.api.nvim_create_user_command(
|
||||||
command_name,
|
command_name,
|
||||||
function()
|
function()
|
||||||
|
|
@ -73,8 +73,8 @@ end
|
||||||
-- end ]]--
|
-- end ]]--
|
||||||
-- end
|
-- end
|
||||||
-- ct.map('n', '<Leader>c', '<cmd>lua toggle_background()<CR>')
|
-- ct.map('n', '<Leader>c', '<cmd>lua toggle_background()<CR>')
|
||||||
|
|
||||||
ct.map('n', '<Leader>b', ':buffer<Space><C-z>')
|
ct.map('n', '<Leader>b', ':buffer<Space><C-z>')
|
||||||
|
ct.map('n', '<Leader>h', '<cmd>lua vim.lsp.buf.hover()<CR>')
|
||||||
--
|
--
|
||||||
-- Commands
|
-- Commands
|
||||||
--
|
--
|
||||||
|
|
|
||||||
|
|
@ -39,10 +39,10 @@ vim.g.netrw_browse_split = 0
|
||||||
--
|
--
|
||||||
-- EtC.
|
-- EtC.
|
||||||
--
|
--
|
||||||
vim.opt.clipboard = "unnamedplus"
|
-- vim.opt.clipboard = "unnamedplus"
|
||||||
vim.opt.compatible = false
|
vim.opt.compatible = false
|
||||||
vim.opt.autowrite = true
|
vim.opt.autowrite = true
|
||||||
vim.opt.foldmethod = "marker"
|
vim.opt.foldmethod = "syntax"
|
||||||
-- auto cd to the current file's location
|
-- auto cd to the current file's location
|
||||||
vim.cmd('autocmd BufEnter * silent! lcd %:p:h')
|
vim.cmd('autocmd BufEnter * silent! lcd %:p:h')
|
||||||
-- highlighting for other langs in markdown docs
|
-- highlighting for other langs in markdown docs
|
||||||
|
|
|
||||||
|
|
@ -93,6 +93,8 @@ return {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
{ 'jlcrochet/vim-razor', lazy = false },
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Language Server
|
-- Language Server
|
||||||
--
|
--
|
||||||
|
|
@ -169,6 +171,7 @@ return {
|
||||||
"html",
|
"html",
|
||||||
"jsonls",
|
"jsonls",
|
||||||
"lua_ls",
|
"lua_ls",
|
||||||
|
"omnisharp",
|
||||||
"phpactor",
|
"phpactor",
|
||||||
"pyright",
|
"pyright",
|
||||||
"sqls",
|
"sqls",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue