3DFJKTDVL7O4RYWXKC7HEE2VFDWUZVE33DZP4QIJ6MO3ANQXD4LQC
LSNQNAVVNEDKBRU7BGHM6RQOGAL6LPFVJK2HKJ72YLXHL2LVE2SQC
DEVZGQYDMMD2ZMJKQX5M72L4LTYAZEIVEDXSYNIMHMRBT5CJIERAC
QWJ5FBQ7ZL75GTXLYEVPTLK7AEMBMBEYE7536WFLGINTG332LAIAC
4U7EI3UFCICTPJR67H73GZWH25W42MNABJSKVFW6ARLFR5XJTCQQC
CQGP4UVTVLKYTCQU662OFNXSOKZKAQ45RWK273Z4SZUMTOEVKKMQC
XQD63RAJU5FUZXMP2WXIHHNFFSEP7TNHYZFO3DCPPYFBHWLXW6DAC
local opts = { noremap=true, silent=true }
-- there are several goto def/impl/decl actions. this first one is my favorite
buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.definition()<cr>', opts)
-- the traditional mapping
-- buf_set_keymap(bufnr, 'n', '<c-]>', '<cmd>lua vim.lsp.buf.definition()<cr>', opts)
-- require 'cmp_nvim_lsp'.update_cababilities(vim.lsp.protocol.make_client_capabilities)
buf_set_keymap(bufnr, 'n', 'K', '<cmd>lua vim.lsp.buf.hover()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', '<c-k>', '<cmd>lua vim.lsp.buf.signature_help()<cr>', opts)
buf_set_keymap(bufnr, 'n', '1gD', '<cmd>lua vim.lsp.buf.type_definition()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua require\'telescope.builtin\'.lsp_references()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'g0', '<cmd>lua require\'telescope.builtin\'.lsp_document_symbols()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gw', '<cmd>lua require\'telescope.builtin\'.lsp_workspace_symbols()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua vim.lsp.buf.references()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'g0', '<cmd>lua vim.lsp.buf.document_symbol()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'gW', '<cmd>lua vim.lsp.buf.workspace_symbol()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>r', '<cmd>lua vim.lsp.buf.rename()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>d', '<cmd>lua vim.diagnostic.show_line_diagnostics()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>a', '<cmd>lua vim.lsp.buf.code_action()<cr>', opts)
local opts = { noremap=true, silent=true }
-- there are several goto def/impl/decl actions. this first one is my favorite
buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.definition()<cr>', opts)
-- the traditional mapping
-- buf_set_keymap(bufnr, 'n', '<c-]>', '<cmd>lua vim.lsp.buf.definition()<cr>', opts)
-- configuration for diagnostics
buf_set_keymap(bufnr, 'n', 'g[', '<cmd>lua vim.diagnostic.goto_prev()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'g]', '<cmd>lua vim.diagnostic.goto_next()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'K', '<cmd>lua vim.lsp.buf.hover()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', '<c-k>', '<cmd>lua vim.lsp.buf.signature_help()<cr>', opts)
buf_set_keymap(bufnr, 'n', '1gD', '<cmd>lua vim.lsp.buf.type_definition()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua require\'telescope.builtin\'.lsp_references()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'g0', '<cmd>lua require\'telescope.builtin\'.lsp_document_symbols()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'gw', '<cmd>lua require\'telescope.builtin\'.lsp_workspace_symbols()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua vim.lsp.buf.references()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'g0', '<cmd>lua vim.lsp.buf.document_symbol()<cr>', opts)
-- buf_set_keymap(bufnr, 'n', 'gW', '<cmd>lua vim.lsp.buf.workspace_symbol()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>r', '<cmd>lua vim.lsp.buf.rename()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>d', '<cmd>lua vim.diagnostic.show_line_diagnostics()<cr>', opts)
buf_set_keymap(bufnr, 'n', '<localleader>a', '<cmd>lua vim.lsp.buf.code_action()<cr>', opts)
-- TODO: add a mapping for goto implementation
-- buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.implementation()<cr>', opts)
-- configuration for diagnostics
buf_set_keymap(bufnr, 'n', 'g[', '<cmd>lua vim.diagnostic.goto_prev()<cr>', opts)
buf_set_keymap(bufnr, 'n', 'g]', '<cmd>lua vim.diagnostic.goto_next()<cr>', opts)
-- TODO: add a mapping for goto implementation
-- buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.implementation()<cr>', opts)
use 'wbthomason/packer.nvim'
-- UI Elements
use { 'junegunn/fzf', run = function() vim.cmd[[fzf#install()]] end }
use 'junegunn/fzf.vim'
use {
'nvim-telescope/telescope.nvim',
requires = {{'nvim-lua/popup.nvim'}, {'nvim-lua/plenary.nvim'}}
}
use 'airblade/vim-gitgutter'
use 'hoob3rt/lualine.nvim'
use 'romgrk/barbar.nvim'
use 'lambdalisue/fern.vim'
use 'voldikss/vim-floaterm'
use 'mfussenegger/nvim-dap'
use 'AckslD/nvim-neoclip.lua'
use 'SmiteshP/nvim-gps'
use 'wbthomason/packer.nvim'
-- UI Elements
use { 'junegunn/fzf', run = function() vim.cmd[[fzf#install()]] end }
use 'junegunn/fzf.vim'
use {
'nvim-telescope/telescope.nvim',
requires = {'nvim-lua/popup.nvim', 'nvim-lua/plenary.nvim'}
}
use 'airblade/vim-gitgutter'
use 'hoob3rt/lualine.nvim'
use 'romgrk/barbar.nvim'
use 'lambdalisue/fern.vim'
use 'voldikss/vim-floaterm'
use 'mfussenegger/nvim-dap'
use 'AckslD/nvim-neoclip.lua'
use 'SmiteshP/nvim-gps'
-- Editing functionality
use 'numToStr/Comment.nvim'
use 'tpope/vim-obsession'
use 'tpope/vim-surround'
use 'tpope/vim-repeat'
use 'nvim-treesitter/nvim-treesitter-textobjects'
use 'windwp/nvim-autopairs'
-- Editing functionality
use 'numToStr/Comment.nvim'
use 'tpope/vim-obsession'
use 'tpope/vim-surround'
use 'tpope/vim-repeat'
use 'nvim-treesitter/nvim-treesitter-textobjects'
use 'windwp/nvim-autopairs'
-- LSP support
use 'neovim/nvim-lspconfig'
use 'nvim-lua/lsp_extensions.nvim'
use 'kosayoda/nvim-lightbulb'
-- use 'hrsh7th/nvim-compe'
use {
'hrsh7th/nvim-cmp',
requires = {
'quangnguyen30192/cmp-nvim-tags',
'hrsh7th/cmp-nvim-lsp',
'hrsh7th/cmp-path',
'hrsh7th/cmp-cmdline',
}
-- LSP support
use 'neovim/nvim-lspconfig'
use 'nvim-lua/lsp_extensions.nvim'
use 'kosayoda/nvim-lightbulb'
-- use 'hrsh7th/nvim-compe'
use {
'hrsh7th/nvim-cmp',
requires = {
'quangnguyen30192/cmp-nvim-tags',
'hrsh7th/cmp-nvim-lsp',
'hrsh7th/cmp-path',
'hrsh7th/cmp-cmdline',
-- Aesthetic plugins
use 'eddyekofo94/gruvbox-flat.nvim'
use 'sheerun/vim-polyglot'
-- use { 'nvim-treesitter/nvim-treesitter', branch = '0.5-compat', run = ':TSUpdate' }
use { 'nvim-treesitter/nvim-treesitter', run = ':TSUpdate' }
use 'nvim-treesitter/playground'
-- Aesthetic plugins
use 'eddyekofo94/gruvbox-flat.nvim'
use 'sheerun/vim-polyglot'
-- use { 'nvim-treesitter/nvim-treesitter', branch = '0.5-compat', run = ':TSUpdate' }
use { 'nvim-treesitter/nvim-treesitter', run = ':TSUpdate' }
use 'nvim-treesitter/playground'
highlight = {
enable = true,
-- disable = {'rust', 'python'} -- list of languages to disable
ensure_installed = "all",
highlight = {
enable = true,
-- disable = {'rust', 'python'} -- list of languages to disable
},
incremental_selection = {
enable = true,
keymaps = {
init_selection = 's',
node_incremental = 'sn',
scope_incremental = 'ss',
node_decremental = 'sd'
incremental_selection = {
enable = true,
keymaps = {
init_selection = 's',
node_incremental = 'sn',
scope_incremental = 'ss',
node_decremental = 'sd'
},
-- disable = {'rust'}
-- disable = {'rust'}
},
indent = {
enable = true,
disable = {'c', 'cpp', 'python', 'rust'}
},
playground = {
enable = true,
disable = {},
updatetime = 25,
persist_queries = false
},
textobjects = {
select = {
enable = true,
keymaps = {
-- You can use the capture groups defined in textobjects.scm
["af"] = "@function.outer",
["if"] = "@function.inner",
["ac"] = "@class.outer",
["ic"] = "@class.inner",
-- Or you can define your own textobjects like this
-- ["iF"] = {
-- python = "(function_definition) @function",
-- cpp = "(function_definition) @function",
-- c = "(function_definition) @function",
-- java = "(method_declaration) @function",
-- },
}
playground = {
enable = true,
disable = {},
updatetime = 25,
persist_queries = false
move = {
enable = true,
set_jumps = false, -- whether to set jumps in the jumplist
goto_next_start = {
["]]"] = "@function.outer",
["]m"] = "@class.outer",
},
goto_next_end = {
["]["] = "@function.outer",
["]M"] = "@class.outer",
},
goto_previous_start = {
["[["] = "@function.outer",
["[m"] = "@class.outer",
},
goto_previous_end = {
["[]"] = "@function.outer",
["[M"] = "@class.outer",
},
textobjects = {
select = {
enable = true,
keymaps = {
-- You can use the capture groups defined in textobjects.scm
["af"] = "@function.outer",
["if"] = "@function.inner",
["ac"] = "@class.outer",
["ic"] = "@class.inner",
-- Or you can define your own textobjects like this
-- ["iF"] = {
-- python = "(function_definition) @function",
-- cpp = "(function_definition) @function",
-- c = "(function_definition) @function",
-- java = "(method_declaration) @function",
-- },
}
},
swap = {
enable = true,
swap_next = {
["<c-.>"] = "@parameter.inner",
},
swap_previous = {
["<c-,>"] = "@parameter.inner",
}
},
move = {
enable = true,
set_jumps = false, -- whether to set jumps in the jumplist
goto_next_start = {
["]]"] = "@function.outer",
["]m"] = "@class.outer",
},
goto_next_end = {
["]["] = "@function.outer",
["]M"] = "@class.outer",
},
goto_previous_start = {
["[["] = "@function.outer",
["[m"] = "@class.outer",
},
goto_previous_end = {
["[]"] = "@function.outer",
["[M"] = "@class.outer",
},
},
},
},