summaryrefslogtreecommitdiffstats
path: root/.config/nvim
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.config/nvim/after/plugin/lsp.lua1
-rw-r--r--.config/nvim/lua/bindings.lua4
-rw-r--r--.config/nvim/lua/settings.lua6
3 files changed, 9 insertions, 2 deletions
diff --git a/.config/nvim/after/plugin/lsp.lua b/.config/nvim/after/plugin/lsp.lua
index e63c38e..1d85a9d 100644
--- a/.config/nvim/after/plugin/lsp.lua
+++ b/.config/nvim/after/plugin/lsp.lua
@@ -31,6 +31,7 @@ require('mason-lspconfig').setup({
'cmake',
'marksman',
'ltex',
+ 'perlnavigator',
},
handlers = {
lsp.default_setup,
diff --git a/.config/nvim/lua/bindings.lua b/.config/nvim/lua/bindings.lua
index d6ada89..73e9980 100644
--- a/.config/nvim/lua/bindings.lua
+++ b/.config/nvim/lua/bindings.lua
@@ -1,6 +1,7 @@
vim.keymap.set('n', '<M-;>', ':call nerdcommenter#Comment(0,"toggle")<CR>', { noremap = true, silent = true })
vim.keymap.set('n', '<M-x>', ':', { noremap = true, silent = false })
vim.keymap.set('n', '<M-k>', ':bprevious<CR>', { noremap = true, silent = true })
+vim.keymap.set('n', '<C-u>', '<C-u>zz', { noremap = true, silent = false })
vim.keymap.set('n', '<M-j>', ':bnext<CR>', { noremap = true, silent = true })
vim.keymap.set('n', '<C-h>', '<C-w>h', { noremap = true, silent = false })
vim.keymap.set('n', '<C-j>', '<C-w>j', { noremap = true, silent = false })
@@ -10,10 +11,11 @@ vim.keymap.set('n', '<C-o>', '<C-w>o', { noremap = true, silent = false })
vim.keymap.set('n', '<C-q>', '<C-w>q', { noremap = true, silent = false })
vim.keymap.set('n', '*', '*zz', { noremap = true, silent = false })
vim.keymap.set('n', '<C-d>', '<C-d>zz', { noremap = true, silent = false })
-vim.keymap.set('n', '<C-u>', '<C-u>zz', { noremap = true, silent = false })
vim.keymap.set('i', '<C-j>', 'pumvisible() ? "<C-n>" : "<C-j>"', { expr = true })
vim.keymap.set('i', '<C-k>', 'pumvisible() ? "<C-p>" : "<C-k>"', { expr = true })
vim.keymap.set('i', '<cr>', 'pumvisible() ? asyncomplete#close_popup() : "\\<cr>"', { expr = true })
vim.g.floaterm_keymap_toggle = '<F1>'
vim.g.floaterm_keymap_prev = '<F11>'
vim.g.floaterm_keymap_next = '<F12>'
+vim.keymap.set('v', 'J', ":m '>+1<CR>gv=gv")
+vim.keymap.set('v', 'K', ":m '<-2<CR>gv=gv")
diff --git a/.config/nvim/lua/settings.lua b/.config/nvim/lua/settings.lua
index 238caea..5ab7155 100644
--- a/.config/nvim/lua/settings.lua
+++ b/.config/nvim/lua/settings.lua
@@ -18,6 +18,8 @@ vim.opt.mouse = 'a'
vim.opt.compatible = false
vim.opt.expandtab = false
vim.opt.hlsearch = false
+vim.opt.incsearch = true
+vim.opt.termguicolors = true
vim.opt.number = true
vim.opt.shiftwidth = 4
vim.opt.softtabstop = 4
@@ -30,6 +32,9 @@ vim.opt.undodir = '/tmp/nvim_undo'
vim.opt.undofile = true
vim.opt.wildmode = 'longest,list,full'
vim.opt.directory = '/tmp/nvim_swap'
+vim.opt.colorcolumn = "80"
+vim.opt.scrolloff = 5
+vim.opt.signcolumn = "yes"
vim.o.ignorecase = true
vim.o.smartcase = true
vim.opt.wrap = true
@@ -45,7 +50,6 @@ autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
]]
vim.g.mapleader = '\\'
vim.g.maplocalleader = '\\'
-vim.g['battery#update_statusline'] = 1
local highlight_group = vim.api.nvim_create_augroup('YankHighlight', { clear = true })
vim.api.nvim_create_autocmd('TextYankPost', {
callback = function()