Merge remote-tracking branch 'refs/remotes/origin/main'
This commit is contained in:
commit
e118e5a13c
3 changed files with 28 additions and 1 deletions
27
init.lua
27
init.lua
|
|
@ -36,6 +36,33 @@ if vim.g.vscode then
|
||||||
end
|
end
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
local vscode = require('vscode')
|
||||||
|
|
||||||
|
local opts = { noremap = true, silent = true }
|
||||||
|
vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, opts)
|
||||||
|
vim.keymap.set('n', 'gd', function()
|
||||||
|
vscode.call("editor.action.revealDefinition")
|
||||||
|
end, opts)
|
||||||
|
vim.keymap.set('n', 'K', vim.lsp.buf.hover, opts)
|
||||||
|
vim.keymap.set('n', 'gi', vim.lsp.buf.implementation, opts)
|
||||||
|
vim.keymap.set('n', '<C-k>', vim.lsp.buf.signature_help, opts)
|
||||||
|
vim.keymap.set('n', '<leader>wa', vim.lsp.buf.add_workspace_folder, opts)
|
||||||
|
vim.keymap.set('n', '<leader>wr', vim.lsp.buf.remove_workspace_folder, opts)
|
||||||
|
vim.keymap.set('n', '<leader>wl', function()
|
||||||
|
print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
|
||||||
|
end, opts)
|
||||||
|
vim.keymap.set('n', '<leader>D', vim.lsp.buf.type_definition, opts)
|
||||||
|
vim.keymap.set('n', '<leader>rn', vim.lsp.buf.rename, opts)
|
||||||
|
vim.keymap.set('n', 'gr', vim.lsp.buf.references, opts)
|
||||||
|
vim.keymap.set('n', '<leader>k', vim.diagnostic.open_float, opts)
|
||||||
|
vim.keymap.set('n', '[d', vim.diagnostic.goto_prev, opts)
|
||||||
|
vim.keymap.set('n', ']d', vim.diagnostic.goto_next, opts)
|
||||||
|
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, opts)
|
||||||
|
vim.keymap.set('n', '<leader>ca', function()
|
||||||
|
vscode.call("editor.action.quickFix")
|
||||||
|
end
|
||||||
|
, opts)
|
||||||
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ tab_bar_min_tabs 1
|
||||||
tab_powerline_style slanted
|
tab_powerline_style slanted
|
||||||
map ctrl+g kitten hints --type=linenum --linenum-action=background sh -c "nvim_remote +{line} {path}"
|
map ctrl+g kitten hints --type=linenum --linenum-action=background sh -c "nvim_remote +{line} {path}"
|
||||||
tab_bar_edge top
|
tab_bar_edge top
|
||||||
include ./theme.conf
|
include ./catppuccin-mocha.conf
|
||||||
map shift+f1 new_tab
|
map shift+f1 new_tab
|
||||||
map shift+f2 new_tab_with_cwd
|
map shift+f2 new_tab_with_cwd
|
||||||
map ctrl+shift+w no_op
|
map ctrl+shift+w no_op
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue