refactor: clean up file tree, remove redundant code, formatting
This commit is contained in:
@@ -1,5 +1,8 @@
|
|||||||
|
vim.opt_local.textwidth = 78
|
||||||
|
vim.opt_local.spell = true
|
||||||
|
|
||||||
return {
|
return {
|
||||||
require('cmp').setup.buffer({
|
require('cmp').setup.buffer({
|
||||||
sources = require('cmp').config.sources({ { name = 'gitmoji' } }, { { name = 'buffer' } }),
|
sources = require('cmp').config.sources({ { name = 'gitmoji' } }, { { name = 'buffer' } }),
|
||||||
}),
|
}),
|
||||||
}
|
}
|
||||||
@@ -1,23 +1,25 @@
|
|||||||
local autocmd = vim.api.nvim_create_autocmd
|
local autocmd = vim.api.nvim_create_autocmd
|
||||||
local augroup = vim.api.nvim_create_augroup
|
local augroup = vim.api.nvim_create_augroup
|
||||||
|
local o = vim.opt_local
|
||||||
|
|
||||||
-- ──────────────────[ set options for markdown files ]───────────────
|
-- ──────────────────[ set options for markdown files ]───────────────
|
||||||
autocmd('FileType', {
|
autocmd('FileType', {
|
||||||
pattern = 'markdown',
|
pattern = 'markdown',
|
||||||
callback = function()
|
callback = function()
|
||||||
vim.opt_local.textwidth = 80
|
o.colorcolumn = '+1,+2'
|
||||||
vim.opt_local.spell = true
|
o.textwidth = 80
|
||||||
|
o.spell = true
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
-- ─────────────────────[ set options for gitcommit ]─────────────────────
|
--[[ -- ─────────────────────[ set options for gitcommit ]─────────────────────
|
||||||
autocmd('FileType', {
|
autocmd('FileType', {
|
||||||
pattern = 'gitcommit',
|
pattern = 'gitcommit',
|
||||||
callback = function()
|
callback = function()
|
||||||
vim.opt_local.textwidth = 78
|
vim.opt_local.textwidth = 78
|
||||||
vim.opt_local.spell = true
|
vim.opt_local.spell = true
|
||||||
end,
|
end,
|
||||||
})
|
}) ]]
|
||||||
|
|
||||||
-- ┌
|
-- ┌
|
||||||
-- │ Highlight on yank
|
-- │ Highlight on yank
|
||||||
@@ -29,4 +31,4 @@ autocmd('TextYankPost', {
|
|||||||
callback = function()
|
callback = function()
|
||||||
vim.highlight.on_yank({ higroup = 'IncSearch', timeout = '800' })
|
vim.highlight.on_yank({ higroup = 'IncSearch', timeout = '800' })
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -9,18 +9,55 @@ local function opts(desc)
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- ───────────────────────────────────────────────────( general use )─
|
-- ───────────────────────────────────────────────────( general use )─
|
||||||
keymap.set('i', 'jk', '<ESC>', opts('Exit insert mode with jk'))
|
keymap.set('i', 'jk', '<ESC>', opts('Exit insert mode'))
|
||||||
keymap.set('n', '<leader>nh', ':nohl<CR>', opts('Clear search highlights'))
|
keymap.set('n', '<leader>nh', ':nohl<CR>', opts('Clear search highlights'))
|
||||||
keymap.set({ 'n', 'v' }, '<leader>cm', '<cmd>Noice dismiss<CR>', opts('Dismiss notifications'))
|
keymap.set({ 'n', 'v' }, '<leader>cm', '<cmd>NoiceDismiss<CR>', opts('Dismiss notifications'))
|
||||||
keymap.set('n', '<leader>?', '<cmd>Telescope help_tags<CR>', opts('Search documentation'))
|
|
||||||
|
-- ─────────────────────────────────────────────────────( telescope )─
|
||||||
|
keymap.set('n', '<leader>fh', '<cmd>Telescope help_tags<CR>', opts('Search documentation'))
|
||||||
|
keymap.set(
|
||||||
|
'n',
|
||||||
|
'<leader>ff',
|
||||||
|
'<cmd>Telescope find_files initial_mode=insert sort_mru=true sort_lastused=true select_current=true<cr>',
|
||||||
|
opts('Fuzzy find files in cwd')
|
||||||
|
)
|
||||||
|
keymap.set(
|
||||||
|
'n',
|
||||||
|
'<leader>fr',
|
||||||
|
'<cmd>Telescope oldfiles initial_mode=insert sort_mru=true sort_lastused=true select_current=true<cr>',
|
||||||
|
opts('Fuzzy find recent files')
|
||||||
|
)
|
||||||
|
keymap.set('n', '<leader>fs', '<cmd>Telescope current_buffer_fuzzy_find<cr>', opts('Find string in this buffer'))
|
||||||
|
keymap.set('n', '<leader>fS', '<cmd>Telescope live_grep<cr>', opts('Find string in cwd'))
|
||||||
|
keymap.set('n', '<leader>fc', '<cmd>Telescope grep_string<cr>', opts('Find string under cursor in cwd'))
|
||||||
|
keymap.set(
|
||||||
|
'n',
|
||||||
|
'<leader>ft',
|
||||||
|
'<cmd>TodoTelescope initial_mode=normal sort_mru=true sort_lastused=true select_current=true<cr>',
|
||||||
|
opts('Find todos')
|
||||||
|
)
|
||||||
|
keymap.set(
|
||||||
|
'n',
|
||||||
|
'<leader>fb',
|
||||||
|
'<cmd>Telescope buffers initial_mode=normal sort_mru=true sort_lastused=true select_current=true<cr>',
|
||||||
|
opts('Select from open buffers')
|
||||||
|
)
|
||||||
|
keymap.set(
|
||||||
|
'n',
|
||||||
|
'<leader>fn',
|
||||||
|
'<cmd>Telescope find_files cwd=' .. vim.fn.stdpath('config') .. '<cr>',
|
||||||
|
opts('Edit nvim config')
|
||||||
|
)
|
||||||
|
keymap.set('n', '<leader>fm', '<cmd>NoiceTelescope<cr>', opts('Open messages with Telescope'))
|
||||||
|
|
||||||
-- ──────────────────────────────────────────────────────( run code )─
|
-- ──────────────────────────────────────────────────────( run code )─
|
||||||
|
keymap.set('n', '<leader>cr', '<cmd>MdEval<CR>', opts('Execute markdown codeblock'))
|
||||||
keymap.set('n', '<leader><leader>x', '<cmd>source %<CR>', opts('Execute the current file'))
|
keymap.set('n', '<leader><leader>x', '<cmd>source %<CR>', opts('Execute the current file'))
|
||||||
keymap.set('n', '<leader>cx', ':.lua<CR>', opts('Execute current line'))
|
keymap.set('n', '<leader>cx', ':.lua<CR>', opts('Execute current line'))
|
||||||
keymap.set('v', '<leader>cx', ':lua<CR>', opts('Execute selected code'))
|
keymap.set('v', '<leader>cx', ':lua<CR>', opts('Execute selected code'))
|
||||||
|
|
||||||
-- ────────────────────────────────────────────────────( formatting )─
|
-- ────────────────────────────────────────────────────( formatting )─
|
||||||
keymap.set({ 'n', 'v' }, '<leader>F', function()
|
keymap.set({ 'n', 'v' }, '<leader>cF', function()
|
||||||
require('conform').format({
|
require('conform').format({
|
||||||
lsp_fallback = true,
|
lsp_fallback = true,
|
||||||
async = false,
|
async = false,
|
||||||
@@ -29,7 +66,7 @@ keymap.set({ 'n', 'v' }, '<leader>F', function()
|
|||||||
end, opts('Format file or selection'))
|
end, opts('Format file or selection'))
|
||||||
|
|
||||||
-- ───────────────────────────────────────────────────────( linting )─
|
-- ───────────────────────────────────────────────────────( linting )─
|
||||||
keymap.set('n', '<leader>l', function()
|
keymap.set('n', '<leader>cl', function()
|
||||||
require('lint').try_lint()
|
require('lint').try_lint()
|
||||||
end, opts('Trigger linting for current file'))
|
end, opts('Trigger linting for current file'))
|
||||||
|
|
||||||
@@ -37,6 +74,16 @@ end, opts('Trigger linting for current file'))
|
|||||||
keymap.set('n', '<leader>+', '<C-a>', opts('Increment number'))
|
keymap.set('n', '<leader>+', '<C-a>', opts('Increment number'))
|
||||||
keymap.set('n', '<leader>-', '<C-x>', opts('Decrement number'))
|
keymap.set('n', '<leader>-', '<C-x>', opts('Decrement number'))
|
||||||
|
|
||||||
|
-- ────────────────────────────────────────────────────( bufferline )─
|
||||||
|
keymap.set('n', '<leader>bp', '<cmd>BufferLineTogglePin<CR>', opts('Toggle pinned tab'))
|
||||||
|
keymap.set('n', '<leader>bg', '<cmd>BufferLinePick<CR>', opts('Pick tab'))
|
||||||
|
keymap.set('n', '<leader>bx', '<cmd>bdelete<CR>', opts('Close tab'))
|
||||||
|
keymap.set('n', '<leader>bX', '<cmd>BufferLineCloseOthers<CR>', opts('Close other tabs'))
|
||||||
|
keymap.set('n', ']b', '<cmd>BufferLineCycleNext<CR>', opts('Next tab'))
|
||||||
|
keymap.set('n', '[b', '<cmd>BufferLineCyclePrev<CR>', opts('Previous tab'))
|
||||||
|
keymap.set('n', '<S-L>', '<cmd>BufferLineMoveNext<CR>', opts('Move tab to the right'))
|
||||||
|
keymap.set('n', '<S-H>', '<cmd>BufferLineMovePrev<CR>', opts('Move tab to the left'))
|
||||||
|
|
||||||
-- ──────────────────────────────────────────────( split management )─
|
-- ──────────────────────────────────────────────( split management )─
|
||||||
keymap.set('n', '<leader>sv', '<C-w>v', opts('Split window vertically'))
|
keymap.set('n', '<leader>sv', '<C-w>v', opts('Split window vertically'))
|
||||||
keymap.set('n', '<leader>sh', '<C-w>s', opts('Split window horizontally'))
|
keymap.set('n', '<leader>sh', '<C-w>s', opts('Split window horizontally'))
|
||||||
@@ -51,16 +98,6 @@ keymap.set('n', '<leader>tx', '<cmd>tabclose<CR>', opts('Close current tab'))
|
|||||||
-- keymap.set("n", "<leader>tp", "<cmd>tabp<CR>", opts("Go to previous tab"))
|
-- keymap.set("n", "<leader>tp", "<cmd>tabp<CR>", opts("Go to previous tab"))
|
||||||
keymap.set('n', '<leader>tf', '<cmd>tabnew %<CR>', opts('Open current buffer in new tab'))
|
keymap.set('n', '<leader>tf', '<cmd>tabnew %<CR>', opts('Open current buffer in new tab'))
|
||||||
|
|
||||||
-- ────────────────────────────────────────────────────( bufferline )─
|
|
||||||
keymap.set('n', '<leader>bp', '<cmd>BufferLineTogglePin<CR>', opts('Toggle pinned tab'))
|
|
||||||
keymap.set('n', '<leader>bg', '<cmd>BufferLinePick<CR>', opts('Pick tab'))
|
|
||||||
keymap.set('n', '<leader>bx', '<cmd>bdelete<CR>', opts('Close tab'))
|
|
||||||
keymap.set('n', '<leader>bX', '<cmd>BufferLineCloseOthers<CR>', opts('Close other tabs'))
|
|
||||||
keymap.set('n', ']b', '<cmd>BufferLineCycleNext<CR>', opts('Next tab'))
|
|
||||||
keymap.set('n', '[b', '<cmd>BufferLineCyclePrev<CR>', opts('Previous tab'))
|
|
||||||
keymap.set('n', '<S-L>', '<cmd>BufferLineMoveNext<CR>', opts('Move tab to the right'))
|
|
||||||
keymap.set('n', '<S-H>', '<cmd>BufferLineMovePrev<CR>', opts('Move tab to the left'))
|
|
||||||
|
|
||||||
-- ────────────────────────────────────────────( session management )─
|
-- ────────────────────────────────────────────( session management )─
|
||||||
keymap.set('n', '<leader>wa', '<cmd>SessionToggleAutoSave<CR>', opts('Toggle session autosave'))
|
keymap.set('n', '<leader>wa', '<cmd>SessionToggleAutoSave<CR>', opts('Toggle session autosave'))
|
||||||
keymap.set('n', '<leader>wD', '<cmd>Autosession delete<CR>', opts('Delete a session'))
|
keymap.set('n', '<leader>wD', '<cmd>Autosession delete<CR>', opts('Delete a session'))
|
||||||
@@ -107,41 +144,6 @@ keymap.set(
|
|||||||
opts('Open todos in trouble')
|
opts('Open todos in trouble')
|
||||||
)
|
)
|
||||||
|
|
||||||
-- ─────────────────────────────────────────────────────( telescope )─
|
|
||||||
keymap.set(
|
|
||||||
'n',
|
|
||||||
'<leader>ff',
|
|
||||||
'<cmd>Telescope find_files initial_mode=insert sort_mru=true sort_lastused=true select_current=true<cr>',
|
|
||||||
opts('Fuzzy find files in cwd')
|
|
||||||
)
|
|
||||||
keymap.set(
|
|
||||||
'n',
|
|
||||||
'<leader>fr',
|
|
||||||
'<cmd>Telescope oldfiles initial_mode=insert sort_mru=true sort_lastused=true select_current=true<cr>',
|
|
||||||
opts('Fuzzy find recent files')
|
|
||||||
)
|
|
||||||
keymap.set('n', '<leader>fs', '<cmd>Telescope current_buffer_fuzzy_find<cr>', opts('Find string in this buffer'))
|
|
||||||
keymap.set('n', '<leader>fS', '<cmd>Telescope live_grep<cr>', opts('Find string in cwd'))
|
|
||||||
keymap.set('n', '<leader>fc', '<cmd>Telescope grep_string<cr>', opts('Find string under cursor in cwd'))
|
|
||||||
keymap.set(
|
|
||||||
'n',
|
|
||||||
'<leader>ft',
|
|
||||||
'<cmd>TodoTelescope initial_mode=normal sort_mru=true sort_lastused=true select_current=true<cr>',
|
|
||||||
opts('Find todos')
|
|
||||||
)
|
|
||||||
keymap.set(
|
|
||||||
'n',
|
|
||||||
'<leader>fb',
|
|
||||||
'<cmd>Telescope buffers initial_mode=normal sort_mru=true sort_lastused=true select_current=true<cr>',
|
|
||||||
opts('Select from open buffers')
|
|
||||||
)
|
|
||||||
keymap.set(
|
|
||||||
'n',
|
|
||||||
'<leader>fn',
|
|
||||||
'<cmd>Telescope find_files cwd=' .. vim.fn.stdpath('config') .. '<cr>',
|
|
||||||
opts('Edit nvim config')
|
|
||||||
)
|
|
||||||
|
|
||||||
-- ────────────────────────────────────────────────────( substitute )─
|
-- ────────────────────────────────────────────────────( substitute )─
|
||||||
keymap.set('n', 's', function()
|
keymap.set('n', 's', function()
|
||||||
require('substitute').operator()
|
require('substitute').operator()
|
||||||
@@ -156,7 +158,7 @@ keymap.set('x', 's', function()
|
|||||||
require('substitute').visual()
|
require('substitute').visual()
|
||||||
end, opts('Substitute in visual mode'))
|
end, opts('Substitute in visual mode'))
|
||||||
|
|
||||||
-- ─────────────────────────────────────────────────────( nvim-tree )─
|
-- ──────────────────────────────────────────────────( file browser )─
|
||||||
keymap.set('n', '<leader>ee', '<cmd>NvimTreeToggle<CR>', opts('Toggle file explorer'))
|
keymap.set('n', '<leader>ee', '<cmd>NvimTreeToggle<CR>', opts('Toggle file explorer'))
|
||||||
keymap.set('n', '<leader>ef', '<cmd>NvimTreeFindFileToggle<CR>', opts('Toggle file explorer on current file'))
|
keymap.set('n', '<leader>ef', '<cmd>NvimTreeFindFileToggle<CR>', opts('Toggle file explorer on current file'))
|
||||||
keymap.set('n', '<leader>ec', '<cmd>NvimTreeCollapse<CR>', opts('Collapse file explorer'))
|
keymap.set('n', '<leader>ec', '<cmd>NvimTreeCollapse<CR>', opts('Collapse file explorer'))
|
||||||
@@ -171,10 +173,10 @@ end, opts('Diff this'))
|
|||||||
keymap.set('n', '<leader>hD', function()
|
keymap.set('n', '<leader>hD', function()
|
||||||
require('gitsigns').diffthis('~')
|
require('gitsigns').diffthis('~')
|
||||||
end, opts('Diff this ~'))
|
end, opts('Diff this ~'))
|
||||||
|
vim.keymap.set('n', '<leader>hw', '<cmd>Gitsigns toggle_word_diff', opts('Toggle word diff'))
|
||||||
|
|
||||||
-- ───────────────────────────────────────────────────────────( git )─
|
-- ───────────────────────────────────────────────────────────( git )─
|
||||||
keymap.set('n', '<leader>Lg', '<cmd>LazyGit<cr>', opts('Open LazyGit'))
|
keymap.set('n', '<leader>Lg', '<cmd>LazyGit<cr>', opts('Open LazyGit'))
|
||||||
vim.keymap.set('n', '<leader>hw', '<cmd>Gitsigns toggle_word_diff', opts('Toggle word diff'))
|
|
||||||
keymap.set('n', ']h', function()
|
keymap.set('n', ']h', function()
|
||||||
require('gitsigns').nav_hunk('next')
|
require('gitsigns').nav_hunk('next')
|
||||||
end, opts('Next hunk'))
|
end, opts('Next hunk'))
|
||||||
@@ -227,9 +229,6 @@ keymap.set('n', '<leader>cp', '<cmd>CccPick<CR>', opts('Open color picker'))
|
|||||||
keymap.set({ 'n', 'v' }, '<leader>cv', '<cmd>CccConvert<CR>', opts('Convert color'))
|
keymap.set({ 'n', 'v' }, '<leader>cv', '<cmd>CccConvert<CR>', opts('Convert color'))
|
||||||
keymap.set('n', '<leader>cc', '<cmd>CccHighlighterToggle<CR>', opts('Toggle rendered colors'))
|
keymap.set('n', '<leader>cc', '<cmd>CccHighlighterToggle<CR>', opts('Toggle rendered colors'))
|
||||||
|
|
||||||
-- ──────────────────────────────────────────────────────( markdown )─
|
|
||||||
keymap.set('n', '<leader>cr', '<cmd>MdEval<CR>', opts('Execute markdown codeblock'))
|
|
||||||
|
|
||||||
-- ────────────────────────────────────────────────────( spellcheck )─
|
-- ────────────────────────────────────────────────────( spellcheck )─
|
||||||
keymap.set('n', '<leader>S', function()
|
keymap.set('n', '<leader>S', function()
|
||||||
if vim.wo.spell then
|
if vim.wo.spell then
|
||||||
@@ -244,4 +243,4 @@ keymap.set('i', '<C-s>', function()
|
|||||||
else
|
else
|
||||||
vim.opt_local.spell = true
|
vim.opt_local.spell = true
|
||||||
end
|
end
|
||||||
end, opts('Toggle spell check'))
|
end, opts('Toggle spell check'))
|
||||||
|
|||||||
@@ -22,14 +22,6 @@ o.number = true
|
|||||||
o.relativenumber = true
|
o.relativenumber = true
|
||||||
-- ──────────────────────────────────────────────────── sign column ──
|
-- ──────────────────────────────────────────────────── sign column ──
|
||||||
o.signcolumn = 'yes'
|
o.signcolumn = 'yes'
|
||||||
-- ─────────────────────────────────────────────────────── markdown ──
|
|
||||||
vim.api.nvim_create_autocmd('BufWinEnter', {
|
|
||||||
pattern = { '*.md' },
|
|
||||||
callback = function()
|
|
||||||
o.colorcolumn = '+1,+2'
|
|
||||||
o.textwidth = 80
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
-- ──────────────────────────────────────────────────── cursor line ──
|
-- ──────────────────────────────────────────────────── cursor line ──
|
||||||
o.cursorline = true
|
o.cursorline = true
|
||||||
-- o.scrolloff = 999 -- keep cursor line centered
|
-- o.scrolloff = 999 -- keep cursor line centered
|
||||||
@@ -95,4 +87,4 @@ o.ignorecase = true
|
|||||||
o.smartcase = true
|
o.smartcase = true
|
||||||
o.iskeyword:append('-') -- consider string-string as a whole word
|
o.iskeyword:append('-') -- consider string-string as a whole word
|
||||||
-- ───────────────────────────────────────────────────── completion ──
|
-- ───────────────────────────────────────────────────── completion ──
|
||||||
o.completeopt = 'menu,preview,noselect'
|
o.completeopt = 'menu,preview,noselect'
|
||||||
@@ -182,12 +182,11 @@ return {
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
-- FIX: on my Arch laptop, 't' as first character on cmdline escapes
|
|
||||||
-- the cmdline and destructively prints xx:xx to the document
|
|
||||||
cmp.setup.cmdline(':', {
|
cmp.setup.cmdline(':', {
|
||||||
enabled = function()
|
enabled = function()
|
||||||
local disabled = {
|
local disabled = {
|
||||||
-- list of commands to disable completions
|
-- list of commands to disable completions
|
||||||
|
wa = true,
|
||||||
wq = true,
|
wq = true,
|
||||||
wqa = true,
|
wqa = true,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,4 +24,4 @@ return {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,13 @@
|
|||||||
return {
|
return {
|
||||||
'stevearc/dressing.nvim',
|
'stevearc/dressing.nvim',
|
||||||
dependencies = {
|
|
||||||
'nvim-telescope/telescope.nvim',
|
|
||||||
},
|
|
||||||
event = 'VeryLazy',
|
event = 'VeryLazy',
|
||||||
opts = {
|
opts = {
|
||||||
input = {
|
input = {
|
||||||
enabled = true,
|
enabled = true,
|
||||||
-- default_prompt = 'Prompt',
|
|
||||||
prompt_align = 'left',
|
prompt_align = 'left',
|
||||||
|
trim_prompt = 'true',
|
||||||
insert_only = false,
|
insert_only = false,
|
||||||
|
-- start_mode = 'insert',
|
||||||
start_in_insert = true,
|
start_in_insert = true,
|
||||||
border = 'rounded',
|
border = 'rounded',
|
||||||
relative = 'cursor',
|
relative = 'cursor',
|
||||||
@@ -27,9 +25,6 @@ return {
|
|||||||
['<Down>'] = 'HistoryNext',
|
['<Down>'] = 'HistoryNext',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
override = function(conf)
|
|
||||||
return conf
|
|
||||||
end,
|
|
||||||
},
|
},
|
||||||
select = {
|
select = {
|
||||||
enabled = true,
|
enabled = true,
|
||||||
@@ -44,9 +39,11 @@ return {
|
|||||||
['<CR>'] = 'Confirm',
|
['<CR>'] = 'Confirm',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
override = function(conf)
|
},
|
||||||
return conf
|
nui = {
|
||||||
end,
|
win_options = {
|
||||||
|
winblend = 0.7,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,4 +9,4 @@ return {
|
|||||||
seps = { '' },
|
seps = { '' },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,15 @@
|
|||||||
return {
|
return {
|
||||||
'tpope/vim-fugitive',
|
'tpope/vim-fugitive',
|
||||||
cmd = { 'Git', 'Gdiffsplit', 'Gedit', 'Gvdiffsplit', 'Gread', 'Gwrite', 'Ggrep', 'GMove', 'GDelete', 'GBrowse' },
|
cmd = {
|
||||||
}
|
'Git',
|
||||||
|
'Gdiffsplit',
|
||||||
|
'Gedit',
|
||||||
|
'Gvdiffsplit',
|
||||||
|
'Gread',
|
||||||
|
'Gwrite',
|
||||||
|
'Ggrep',
|
||||||
|
'GMove',
|
||||||
|
'GDelete',
|
||||||
|
'GBrowse',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|||||||
@@ -39,7 +39,8 @@ return {
|
|||||||
numhl = true,
|
numhl = true,
|
||||||
linehl = false,
|
linehl = false,
|
||||||
word_diff = false,
|
word_diff = false,
|
||||||
show_deleted = false, -- turning this off for now as it seems to be slowing down neovim on MBP
|
trouble = true,
|
||||||
|
show_deleted = false,
|
||||||
watch_gitdir = {
|
watch_gitdir = {
|
||||||
interval = 1000,
|
interval = 1000,
|
||||||
follow_files = true,
|
follow_files = true,
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ return {
|
|||||||
event = { 'BufReadPre', 'BufNewFile' },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
opts = {
|
opts = {
|
||||||
providers = {
|
providers = {
|
||||||
'lsp',
|
'nvim_lsp',
|
||||||
'treesitter',
|
'treesitter',
|
||||||
'regex',
|
'regex',
|
||||||
},
|
},
|
||||||
@@ -14,6 +14,8 @@ return {
|
|||||||
'man',
|
'man',
|
||||||
'markdown',
|
'markdown',
|
||||||
'md',
|
'md',
|
||||||
|
'oil',
|
||||||
|
'fugitive',
|
||||||
},
|
},
|
||||||
under_cursor = true,
|
under_cursor = true,
|
||||||
min_count_to_highlight = 1,
|
min_count_to_highlight = 1,
|
||||||
|
|||||||
@@ -1,18 +1,18 @@
|
|||||||
return {
|
return {
|
||||||
"lukas-reineke/indent-blankline.nvim",
|
'lukas-reineke/indent-blankline.nvim',
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
main = "ibl",
|
main = 'ibl',
|
||||||
opts = {
|
opts = {
|
||||||
indent = {
|
indent = {
|
||||||
char = "┊",
|
char = '┊',
|
||||||
smart_indent_cap = true,
|
smart_indent_cap = true,
|
||||||
highlight = {
|
highlight = {
|
||||||
"RainbowDelimiterCyan", -- #88c0d0
|
'RainbowDelimiterCyan', -- #88c0d0
|
||||||
"RainbowDelimiterBlue", -- #81a1c1
|
'RainbowDelimiterBlue', -- #81a1c1
|
||||||
"RainbowDelimiterGreen", -- #a3be8c
|
'RainbowDelimiterGreen', -- #a3be8c
|
||||||
"RainbowDelimiterViolet", -- #b48ead
|
'RainbowDelimiterViolet', -- #b48ead
|
||||||
"RainbowDelimiterYellow", -- #ebcb8b
|
'RainbowDelimiterYellow', -- #ebcb8b
|
||||||
"RainbowDelimiterRed", -- #d08770
|
'RainbowDelimiterRed', -- #d08770
|
||||||
-- "RainbowDelimiterOrange", -- #d08770
|
-- "RainbowDelimiterOrange", -- #d08770
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -21,22 +21,28 @@ return {
|
|||||||
show_start = true,
|
show_start = true,
|
||||||
show_end = true,
|
show_end = true,
|
||||||
-- highlight = { "Function", "Label" },
|
-- highlight = { "Function", "Label" },
|
||||||
char = "▎",
|
char = '▎',
|
||||||
},
|
},
|
||||||
exclude = {
|
exclude = {
|
||||||
filetypes = {
|
filetypes = {
|
||||||
"lspinfo",
|
'lspinfo',
|
||||||
"checkhealth",
|
'checkhealth',
|
||||||
"help",
|
'help',
|
||||||
"man",
|
'man',
|
||||||
"gitcommit",
|
'gitcommit',
|
||||||
"TelescopePrompt",
|
'TelescopePrompt',
|
||||||
"TelescopeResults",
|
'TelescopeResults',
|
||||||
"",
|
'',
|
||||||
"dashboard",
|
'alpha',
|
||||||
"alpha",
|
'NvimTree',
|
||||||
"NvimTree",
|
},
|
||||||
|
buftypes = {
|
||||||
|
'dashboard',
|
||||||
|
'terminal',
|
||||||
|
'nofile',
|
||||||
|
'quickfix',
|
||||||
|
'prompt',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,13 +1,14 @@
|
|||||||
return {
|
return {
|
||||||
"kdheepak/lazygit.nvim",
|
-- TODO: replace with toggleterm or something similar..
|
||||||
cmd = {
|
'kdheepak/lazygit.nvim',
|
||||||
"LazyGit",
|
|
||||||
"LazyGitConfig",
|
|
||||||
"LazyGitCurrentFile",
|
|
||||||
"LazyGitFilter",
|
|
||||||
"LazyGitFilterCurrentFile",
|
|
||||||
},
|
|
||||||
dependencies = {
|
dependencies = {
|
||||||
"nvim-lua/plenary.nvim",
|
'nvim-lua/plenary.nvim',
|
||||||
|
},
|
||||||
|
cmd = {
|
||||||
|
'LazyGit',
|
||||||
|
'LazyGitConfig',
|
||||||
|
'LazyGitCurrentFile',
|
||||||
|
'LazyGitFilter',
|
||||||
|
'LazyGitFilterCurrentFile',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,25 +1,31 @@
|
|||||||
return {
|
return {
|
||||||
"mfussenegger/nvim-lint",
|
'mfussenegger/nvim-lint',
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
|
|
||||||
config = function()
|
config = function()
|
||||||
local lint = require "lint"
|
local lint = require('lint')
|
||||||
|
|
||||||
lint.linters_by_ft = {
|
lint.linters_by_ft = {
|
||||||
markdown = { "markdownlint" },
|
markdown = { 'markdownlint' },
|
||||||
html = { "htmlhint" },
|
html = { 'htmlhint' },
|
||||||
json = { "jsonlint" },
|
json = { 'jsonlint' },
|
||||||
bash = { "shellcheck", "shellharden" },
|
sh = { 'shellcheck' },
|
||||||
javascript = { "eslint_d" },
|
zsh = { 'shellcheck' },
|
||||||
typescript = { "eslint_d" },
|
bash = { 'shellcheck' },
|
||||||
javascriptreact = { "eslint_d" },
|
javascript = { 'eslint_d', 'trivy' },
|
||||||
typescriptreact = { "eslint_d" },
|
typescript = { 'eslint_d' },
|
||||||
python = { "pylint" },
|
python = { 'pylint', 'trivy' },
|
||||||
|
ansible = { 'ansiblelint' },
|
||||||
|
gitcommit = { 'gitlint' },
|
||||||
|
docker = { 'trivy' },
|
||||||
|
yaml = { 'yamllint' },
|
||||||
|
editorconfig = { 'editorconfig-checker' },
|
||||||
|
systemd = { 'systemdlint' },
|
||||||
}
|
}
|
||||||
|
|
||||||
local lint_augroup = vim.api.nvim_create_augroup("lint", { clear = true })
|
local lint_augroup = vim.api.nvim_create_augroup('lint', { clear = true })
|
||||||
|
|
||||||
vim.api.nvim_create_autocmd({ "BufEnter", "BufWritePost", "InsertLeave" }, {
|
vim.api.nvim_create_autocmd({ 'BufEnter', 'BufWritePost', 'InsertLeave' }, {
|
||||||
group = lint_augroup,
|
group = lint_augroup,
|
||||||
callback = function()
|
callback = function()
|
||||||
lint.try_lint()
|
lint.try_lint()
|
||||||
|
|||||||
@@ -51,7 +51,6 @@ return {
|
|||||||
mason_tool_installer.setup({
|
mason_tool_installer.setup({
|
||||||
ensure_installed = {
|
ensure_installed = {
|
||||||
'ansible-lint',
|
'ansible-lint',
|
||||||
'beautysh',
|
|
||||||
'black',
|
'black',
|
||||||
'eslint_d',
|
'eslint_d',
|
||||||
'gitlint',
|
'gitlint',
|
||||||
@@ -70,4 +69,4 @@ return {
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
@@ -84,7 +84,7 @@ return {
|
|||||||
|
|
||||||
prose.setup({
|
prose.setup({
|
||||||
wpm = 200.0,
|
wpm = 200.0,
|
||||||
filetypes = { 'markdown', 'asciidoc' },
|
filetypes = { 'markdown', 'asciidoc', 'text' },
|
||||||
placeholders = {
|
placeholders = {
|
||||||
words = nil,
|
words = nil,
|
||||||
minutes = nil,
|
minutes = nil,
|
||||||
@@ -165,6 +165,11 @@ return {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
lualine_x = {
|
lualine_x = {
|
||||||
|
--[[ {
|
||||||
|
require('noice').api.status.mode.get,
|
||||||
|
cond = require('noice').api.status.mode.has,
|
||||||
|
color = { fg = '#d08770' },
|
||||||
|
}, ]]
|
||||||
{
|
{
|
||||||
-- show status when recording a macro
|
-- show status when recording a macro
|
||||||
function()
|
function()
|
||||||
@@ -272,7 +277,16 @@ return {
|
|||||||
lualine_b = { { 'navic', color_correction = 'nil' } },
|
lualine_b = { { 'navic', color_correction = 'nil' } },
|
||||||
lualine_c = {},
|
lualine_c = {},
|
||||||
lualine_x = {},
|
lualine_x = {},
|
||||||
lualine_y = {},
|
lualine_y = {
|
||||||
|
{
|
||||||
|
'diagnostics',
|
||||||
|
sources = { 'nvim_lsp', 'nvim_workspace_diagnostic', 'nvim_diagnostic' },
|
||||||
|
sections = { 'error', 'warn', 'info' },
|
||||||
|
--symbols = { error = " ", warn = " ", info = " ", hint = " " },
|
||||||
|
colored = true,
|
||||||
|
always_visible = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
lualine_z = {},
|
lualine_z = {},
|
||||||
},
|
},
|
||||||
inactive_winbar = {},
|
inactive_winbar = {},
|
||||||
|
|||||||
@@ -2,19 +2,19 @@ return {
|
|||||||
'willothy/moveline.nvim',
|
'willothy/moveline.nvim',
|
||||||
build = 'make',
|
build = 'make',
|
||||||
keys = {
|
keys = {
|
||||||
{ '<M-[>', mode = 'n' },
|
|
||||||
{ '<M-]>', mode = 'n' },
|
{ '<M-]>', mode = 'n' },
|
||||||
{ '<M-[>', mode = 'v' },
|
|
||||||
{ '<M-]>', mode = 'v' },
|
{ '<M-]>', mode = 'v' },
|
||||||
|
{ '<M-[>', mode = 'n' },
|
||||||
|
{ '<M-[>', mode = 'v' },
|
||||||
},
|
},
|
||||||
|
|
||||||
config = function()
|
config = function()
|
||||||
local moveline = require('moveline')
|
local moveline = require('moveline')
|
||||||
local map = vim.keymap
|
local map = vim.keymap
|
||||||
|
|
||||||
map.set('n', '<M-[>', moveline.up)
|
map.set('n', '<M-]>', moveline.up)
|
||||||
map.set('n', '<M-]>', moveline.down)
|
map.set('n', '<M-[>', moveline.down)
|
||||||
map.set('v', '<M-[>', moveline.block_up)
|
map.set('v', '<M-]>', moveline.block_up)
|
||||||
map.set('v', '<M-]>', moveline.block_down)
|
map.set('v', '<M-[>', moveline.block_down)
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
@@ -8,22 +8,60 @@ return {
|
|||||||
render = 'compact',
|
render = 'compact',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
'nvim-treesitter/nvim-treesitter',
|
||||||
},
|
},
|
||||||
event = 'VeryLazy',
|
event = 'VeryLazy',
|
||||||
opts = {
|
opts = {
|
||||||
lsp = {
|
lsp = {
|
||||||
override = {
|
progress = {
|
||||||
['vim.lsp.util.convert_input_to_markdown_lines'] = true,
|
enabled = true,
|
||||||
['vim.lsp.util.stylize_markdown'] = true,
|
view = 'mini',
|
||||||
['cmp.entry.get_documentation'] = true,
|
|
||||||
},
|
},
|
||||||
|
hover = {
|
||||||
|
enabled = true,
|
||||||
|
silent = true,
|
||||||
|
},
|
||||||
|
signature = {
|
||||||
|
enabled = true,
|
||||||
|
trigger = true,
|
||||||
|
luasnip = true,
|
||||||
|
},
|
||||||
|
message = {
|
||||||
|
enabled = true,
|
||||||
|
view = 'notify',
|
||||||
|
},
|
||||||
|
documentation = {
|
||||||
|
view = 'hover',
|
||||||
|
opts = {
|
||||||
|
lang = 'markdown',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
override = {
|
||||||
|
['vim.lsp.util.convert_input_to_markdown_lines'] = false,
|
||||||
|
['vim.lsp.util.stylize_markdown'] = false,
|
||||||
|
['cmp.entry.get_documentation'] = false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
health = {
|
||||||
|
checker = true,
|
||||||
},
|
},
|
||||||
presets = {
|
presets = {
|
||||||
bottom_search = true,
|
bottom_search = true,
|
||||||
command_palette = false,
|
command_palette = false,
|
||||||
long_message_to_split = true,
|
|
||||||
inc_rename = false,
|
|
||||||
lsp_doc_border = true,
|
lsp_doc_border = true,
|
||||||
},
|
},
|
||||||
|
cmdline = {
|
||||||
|
enabled = true,
|
||||||
|
},
|
||||||
|
messages = {
|
||||||
|
enabled = true,
|
||||||
|
view_error = 'notify',
|
||||||
|
view_warn = 'notify',
|
||||||
|
view_history = 'messages',
|
||||||
|
view_search = 'virtualtext',
|
||||||
|
},
|
||||||
|
popupmenu = {
|
||||||
|
enabled = true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ return {
|
|||||||
color = true,
|
color = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
git_placement = 'after',
|
git_placement = 'signcolumn',
|
||||||
modified_placement = 'after',
|
modified_placement = 'after',
|
||||||
diagnostics_placement = 'signcolumn',
|
diagnostics_placement = 'signcolumn',
|
||||||
padding = ' ',
|
padding = ' ',
|
||||||
@@ -101,4 +101,4 @@ return {
|
|||||||
show_on_open_dirs = true,
|
show_on_open_dirs = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,134 +1,52 @@
|
|||||||
return {
|
return {
|
||||||
'stevearc/oil.nvim',
|
'stevearc/oil.nvim',
|
||||||
---@module 'oil'
|
|
||||||
---@type oil.SetupOpts
|
|
||||||
dependencies = { 'nvim-tree/nvim-web-devicons' },
|
dependencies = { 'nvim-tree/nvim-web-devicons' },
|
||||||
cmd = 'Oil',
|
cmd = 'Oil',
|
||||||
opts = {
|
opts = {
|
||||||
-- Oil will take over directory buffers (e.g. `vim .` or `:e src/`)
|
default_file_explorer = false,
|
||||||
-- Set to false if you want some other plugin (e.g. netrw) to open when you edit directories.
|
|
||||||
default_file_explorer = true,
|
|
||||||
-- Id is automatically added at the beginning, and name at the end
|
|
||||||
-- See :help oil-columns
|
-- See :help oil-columns
|
||||||
columns = {
|
columns = {
|
||||||
'icon',
|
'icon',
|
||||||
-- "permissions",
|
|
||||||
-- "size",
|
|
||||||
-- "mtime",
|
|
||||||
},
|
},
|
||||||
-- Buffer-local options to use for oil buffers
|
|
||||||
buf_options = {
|
buf_options = {
|
||||||
buflisted = false,
|
buflisted = false,
|
||||||
bufhidden = 'hide',
|
bufhidden = 'hide',
|
||||||
},
|
},
|
||||||
-- Window-local options to use for oil buffers
|
|
||||||
win_options = {
|
win_options = {
|
||||||
wrap = false,
|
wrap = false,
|
||||||
signcolumn = 'no',
|
signcolumn = 'yes',
|
||||||
cursorcolumn = false,
|
cursorcolumn = true,
|
||||||
foldcolumn = '0',
|
foldcolumn = '0',
|
||||||
spell = false,
|
spell = false,
|
||||||
list = false,
|
list = false,
|
||||||
conceallevel = 3,
|
conceallevel = 3,
|
||||||
concealcursor = 'nvic',
|
concealcursor = 'nvic',
|
||||||
},
|
},
|
||||||
-- Send deleted files to the trash instead of permanently deleting them (:help oil-trash)
|
delete_to_trash = true,
|
||||||
delete_to_trash = false,
|
skip_confirm_for_simple_edits = true,
|
||||||
-- Skip the confirmation popup for simple operations (:help oil.skip_confirm_for_simple_edits)
|
|
||||||
skip_confirm_for_simple_edits = false,
|
|
||||||
-- Selecting a new/moved/renamed file or directory will prompt you to save changes first
|
|
||||||
-- (:help prompt_save_on_select_new_entry)
|
|
||||||
prompt_save_on_select_new_entry = true,
|
prompt_save_on_select_new_entry = true,
|
||||||
-- Oil will automatically delete hidden buffers after this delay
|
|
||||||
-- You can set the delay to false to disable cleanup entirely
|
|
||||||
-- Note that the cleanup process only starts when none of the oil buffers are currently displayed
|
|
||||||
cleanup_delay_ms = 2000,
|
cleanup_delay_ms = 2000,
|
||||||
lsp_file_methods = {
|
constrain_cursor = 'name',
|
||||||
-- Enable or disable LSP file operations
|
|
||||||
enabled = true,
|
|
||||||
-- Time to wait for LSP file operations to complete before skipping
|
|
||||||
timeout_ms = 1000,
|
|
||||||
-- Set to true to autosave buffers that are updated with LSP willRenameFiles
|
|
||||||
-- Set to "unmodified" to only save unmodified buffers
|
|
||||||
autosave_changes = false,
|
|
||||||
},
|
|
||||||
-- Constrain the cursor to the editable parts of the oil buffer
|
|
||||||
-- Set to `false` to disable, or "name" to keep it on the file names
|
|
||||||
constrain_cursor = 'editable',
|
|
||||||
-- Set to true to watch the filesystem for changes and reload oil
|
|
||||||
watch_for_changes = false,
|
watch_for_changes = false,
|
||||||
-- Keymaps in oil buffer. Can be any value that `vim.keymap.set` accepts OR a table of keymap
|
|
||||||
-- options with a `callback` (e.g. { callback = function() ... end, desc = "", mode = "n" })
|
|
||||||
-- Additionally, if it is a string that matches "actions.<name>",
|
|
||||||
-- it will use the mapping at require("oil.actions").<name>
|
|
||||||
-- Set to `false` to remove a keymap
|
|
||||||
-- See :help oil-actions for a list of all available actions
|
|
||||||
keymaps = {
|
|
||||||
['g?'] = 'actions.show_help',
|
|
||||||
['<CR>'] = 'actions.select',
|
|
||||||
['<C-s>'] = { 'actions.select', opts = { vertical = true }, desc = 'Open the entry in a vertical split' },
|
|
||||||
['<C-h>'] = { 'actions.select', opts = { horizontal = true }, desc = 'Open the entry in a horizontal split' },
|
|
||||||
['<C-t>'] = { 'actions.select', opts = { tab = true }, desc = 'Open the entry in new tab' },
|
|
||||||
['<C-p>'] = 'actions.preview',
|
|
||||||
['<C-c>'] = 'actions.close',
|
|
||||||
['<C-l>'] = 'actions.refresh',
|
|
||||||
['-'] = 'actions.parent',
|
|
||||||
['_'] = 'actions.open_cwd',
|
|
||||||
['`'] = 'actions.cd',
|
|
||||||
['~'] = { 'actions.cd', opts = { scope = 'tab' }, desc = ':tcd to the current oil directory', mode = 'n' },
|
|
||||||
['gs'] = 'actions.change_sort',
|
|
||||||
['gx'] = 'actions.open_external',
|
|
||||||
['g.'] = 'actions.toggle_hidden',
|
|
||||||
['g\\'] = 'actions.toggle_trash',
|
|
||||||
},
|
|
||||||
-- Set to false to disable all of the above keymaps
|
|
||||||
use_default_keymaps = true,
|
use_default_keymaps = true,
|
||||||
view_options = {
|
view_options = {
|
||||||
-- Show files and directories that start with "."
|
show_hidden = true,
|
||||||
show_hidden = false,
|
|
||||||
-- This function defines what is considered a "hidden" file
|
|
||||||
is_hidden_file = function(name, bufnr)
|
is_hidden_file = function(name, bufnr)
|
||||||
local m = name:match('^%.')
|
local m = name:match('^%.')
|
||||||
return m ~= nil
|
return m ~= nil
|
||||||
end,
|
end,
|
||||||
-- This function defines what will never be shown, even when `show_hidden` is set
|
|
||||||
is_always_hidden = function(name, bufnr)
|
is_always_hidden = function(name, bufnr)
|
||||||
return false
|
return false
|
||||||
end,
|
end,
|
||||||
-- Sort file names with numbers in a more intuitive order for humans.
|
|
||||||
-- Can be "fast", true, or false. "fast" will turn it off for large directories.
|
|
||||||
natural_order = 'fast',
|
natural_order = 'fast',
|
||||||
-- Sort file and directory names case insensitive
|
|
||||||
case_insensitive = false,
|
case_insensitive = false,
|
||||||
sort = {
|
sort = {
|
||||||
-- sort order can be "asc" or "desc"
|
|
||||||
-- see :help oil-columns to see which columns are sortable
|
|
||||||
{ 'type', 'asc' },
|
|
||||||
{ 'name', 'asc' },
|
{ 'name', 'asc' },
|
||||||
|
{ 'type', 'asc' },
|
||||||
},
|
},
|
||||||
-- Customize the highlight group for the file name
|
|
||||||
highlight_filename = function(entry, is_hidden, is_link_target, is_link_orphan)
|
|
||||||
return nil
|
|
||||||
end,
|
|
||||||
},
|
},
|
||||||
-- Extra arguments to pass to SCP when moving/copying files over SSH
|
|
||||||
extra_scp_args = {},
|
extra_scp_args = {},
|
||||||
-- EXPERIMENTAL support for performing file operations with git
|
|
||||||
git = {
|
|
||||||
-- Return true to automatically git add/mv/rm files
|
|
||||||
add = function(path)
|
|
||||||
return false
|
|
||||||
end,
|
|
||||||
mv = function(src_path, dest_path)
|
|
||||||
return false
|
|
||||||
end,
|
|
||||||
rm = function(path)
|
|
||||||
return false
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
-- Configuration for the floating window in oil.open_float
|
|
||||||
float = {
|
float = {
|
||||||
-- Padding around the floating window
|
|
||||||
padding = 2,
|
padding = 2,
|
||||||
max_width = 100,
|
max_width = 100,
|
||||||
max_height = 50,
|
max_height = 50,
|
||||||
@@ -136,71 +54,35 @@ return {
|
|||||||
win_options = {
|
win_options = {
|
||||||
winblend = 0,
|
winblend = 0,
|
||||||
},
|
},
|
||||||
-- optionally override the oil buffers window title with custom function: fun(winid: integer): string
|
|
||||||
get_win_title = nil,
|
get_win_title = nil,
|
||||||
-- preview_split: Split direction: "auto", "left", "right", "above", "below".
|
preview_split = 'right',
|
||||||
preview_split = 'auto',
|
|
||||||
-- This is the config that will be passed to nvim_open_win.
|
|
||||||
-- Change values here to customize the layout
|
|
||||||
override = function(conf)
|
|
||||||
return conf
|
|
||||||
end,
|
|
||||||
},
|
},
|
||||||
-- Configuration for the file preview window
|
|
||||||
preview_win = {
|
preview_win = {
|
||||||
-- Whether the preview window is automatically updated when the cursor is moved
|
|
||||||
update_on_cursor_moved = true,
|
update_on_cursor_moved = true,
|
||||||
-- How to open the preview window "load"|"scratch"|"fast_scratch"
|
|
||||||
preview_method = 'fast_scratch',
|
preview_method = 'fast_scratch',
|
||||||
-- A function that returns true to disable preview on a file e.g. to avoid lag
|
|
||||||
disable_preview = function(filename)
|
|
||||||
return false
|
|
||||||
end,
|
|
||||||
-- Window-local options to use for preview window buffers
|
|
||||||
win_options = {},
|
win_options = {},
|
||||||
},
|
},
|
||||||
-- Configuration for the floating action confirmation window
|
|
||||||
confirmation = {
|
confirmation = {
|
||||||
-- Width dimensions can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
max_width = 0.7,
|
||||||
-- min_width and max_width can be a single value or a list of mixed integer/float types.
|
|
||||||
-- max_width = {100, 0.8} means "the lesser of 100 columns or 80% of total"
|
|
||||||
max_width = 0.9,
|
|
||||||
-- min_width = {40, 0.4} means "the greater of 40 columns or 40% of total"
|
|
||||||
min_width = { 40, 0.4 },
|
min_width = { 40, 0.4 },
|
||||||
-- optionally define an integer/float for the exact width of the preview window
|
|
||||||
width = nil,
|
|
||||||
-- Height dimensions can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
|
||||||
-- min_height and max_height can be a single value or a list of mixed integer/float types.
|
|
||||||
-- max_height = {80, 0.9} means "the lesser of 80 columns or 90% of total"
|
|
||||||
max_height = 0.9,
|
max_height = 0.9,
|
||||||
-- min_height = {5, 0.1} means "the greater of 5 columns or 10% of total"
|
|
||||||
min_height = { 5, 0.1 },
|
min_height = { 5, 0.1 },
|
||||||
-- optionally define an integer/float for the exact height of the preview window
|
|
||||||
height = nil,
|
|
||||||
border = 'rounded',
|
border = 'rounded',
|
||||||
win_options = {
|
win_options = {
|
||||||
winblend = 0,
|
winblend = 0,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
-- Configuration for the floating progress window
|
|
||||||
progress = {
|
progress = {
|
||||||
max_width = 0.9,
|
max_width = 0.6,
|
||||||
min_width = { 40, 0.4 },
|
min_width = { 40, 0.4 },
|
||||||
width = nil,
|
|
||||||
max_height = { 10, 0.9 },
|
max_height = { 10, 0.9 },
|
||||||
min_height = { 5, 0.1 },
|
min_height = { 5, 0.1 },
|
||||||
height = nil,
|
|
||||||
border = 'rounded',
|
border = 'rounded',
|
||||||
minimized_border = 'none',
|
minimized_border = 'none',
|
||||||
win_options = {
|
|
||||||
winblend = 0,
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
-- Configuration for the floating SSH window
|
|
||||||
ssh = {
|
ssh = {
|
||||||
border = 'rounded',
|
border = 'rounded',
|
||||||
},
|
},
|
||||||
-- Configuration for the floating keymaps help window
|
|
||||||
keymaps_help = {
|
keymaps_help = {
|
||||||
border = 'rounded',
|
border = 'rounded',
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,13 +1,13 @@
|
|||||||
return {
|
return {
|
||||||
"hedyhli/outline.nvim",
|
'hedyhli/outline.nvim',
|
||||||
lazy = true,
|
lazy = true,
|
||||||
cmd = { "Outline", "OutlineOpen" },
|
cmd = { 'Outline', 'OutlineOpen' },
|
||||||
keys = {
|
keys = {
|
||||||
{ "<leader>o", "<cmd>Outline<CR>", desc = "Toggle outline" },
|
{ '<leader>o', '<cmd>Outline<CR>', desc = 'Toggle outline' },
|
||||||
},
|
},
|
||||||
opts = {
|
opts = {
|
||||||
outline_window = {
|
outline_window = {
|
||||||
position = "right",
|
position = 'right',
|
||||||
width = 25,
|
width = 25,
|
||||||
relative_width = true,
|
relative_width = true,
|
||||||
auto_close = false,
|
auto_close = false,
|
||||||
@@ -18,75 +18,72 @@ return {
|
|||||||
hide_cursor = true,
|
hide_cursor = true,
|
||||||
focus_on_open = false,
|
focus_on_open = false,
|
||||||
},
|
},
|
||||||
|
|
||||||
outline_items = {
|
outline_items = {
|
||||||
show_symbol_details = true,
|
show_symbol_details = true,
|
||||||
show_symbol_lineno = false,
|
show_symbol_lineno = false,
|
||||||
highlight_hovered_item = true,
|
highlight_hovered_item = true,
|
||||||
auto_set_cursor = true,
|
auto_set_cursor = true,
|
||||||
auto_update_events = {
|
auto_update_events = {
|
||||||
follow = { "CursorMoved" },
|
follow = { 'CursorMoved' },
|
||||||
items = { "InsertLeave", "WinEnter", "BufEnter", "BufWinEnter", "TabEnter", "BufWritePost" },
|
items = { 'InsertLeave', 'WinEnter', 'BufEnter', 'BufWinEnter', 'TabEnter', 'BufWritePost' },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
keymaps = {
|
keymaps = {
|
||||||
show_help = "?",
|
show_help = '?',
|
||||||
close = { "<Esc>", "q" },
|
close = { '<Esc>', 'q' },
|
||||||
goto_location = "<Cr>",
|
goto_location = '<Cr>',
|
||||||
peek_location = "o",
|
peek_location = 'o',
|
||||||
goto_and_close = "<S-Cr>",
|
goto_and_close = '<S-Cr>',
|
||||||
restore_location = "<C-g>",
|
restore_location = '<C-g>',
|
||||||
hover_symbol = "<C-space>",
|
hover_symbol = '<C-space>',
|
||||||
toggle_preview = "K",
|
toggle_preview = 'K',
|
||||||
rename_symbol = "r",
|
rename_symbol = 'r',
|
||||||
code_actions = "a",
|
code_actions = 'a',
|
||||||
fold = "h",
|
fold = 'h',
|
||||||
unfold = "l",
|
unfold = 'l',
|
||||||
fold_toggle = "<Tab>",
|
fold_toggle = '<Tab>',
|
||||||
fold_toggle_all = "<S-Tab>",
|
fold_toggle_all = '<S-Tab>',
|
||||||
fold_all = "W",
|
fold_all = 'W',
|
||||||
unfold_all = "E",
|
unfold_all = 'E',
|
||||||
fold_reset = "R",
|
fold_reset = 'R',
|
||||||
down_and_jump = "<C-j>",
|
down_and_jump = '<C-j>',
|
||||||
up_and_jump = "<C-k>",
|
up_and_jump = '<C-k>',
|
||||||
},
|
},
|
||||||
|
|
||||||
symbols = {
|
symbols = {
|
||||||
icons = {
|
icons = {
|
||||||
File = { icon = "", hl = "Identifier" },
|
File = { icon = '', hl = 'Identifier' },
|
||||||
Module = { icon = "", hl = "Include" },
|
Module = { icon = '', hl = 'Include' },
|
||||||
Namespace = { icon = "", hl = "Include" },
|
Namespace = { icon = '', hl = 'Include' },
|
||||||
Package = { icon = "", hl = "Include" },
|
Package = { icon = '', hl = 'Include' },
|
||||||
Class = { icon = "𝓒", hl = "Type" },
|
Class = { icon = '𝓒', hl = 'Type' },
|
||||||
Method = { icon = "ƒ", hl = "Function" },
|
Method = { icon = 'ƒ', hl = 'Function' },
|
||||||
Property = { icon = "", hl = "Identifier" },
|
Property = { icon = '', hl = 'Identifier' },
|
||||||
Field = { icon = "", hl = "Identifier" },
|
Field = { icon = '', hl = 'Identifier' },
|
||||||
Constructor = { icon = "", hl = "Special" },
|
Constructor = { icon = '', hl = 'Special' },
|
||||||
Enum = { icon = "ℰ", hl = "Type" },
|
Enum = { icon = 'ℰ', hl = 'Type' },
|
||||||
Interface = { icon = "", hl = "Type" },
|
Interface = { icon = '', hl = 'Type' },
|
||||||
Function = { icon = "ƒ", hl = "Function" },
|
Function = { icon = 'ƒ', hl = 'Function' },
|
||||||
Variable = { icon = "", hl = "Constant" },
|
Variable = { icon = '', hl = 'Constant' },
|
||||||
Constant = { icon = "", hl = "Constant" },
|
Constant = { icon = '', hl = 'Constant' },
|
||||||
String = { icon = "𝓐", hl = "String" },
|
String = { icon = '𝓐', hl = 'String' },
|
||||||
Number = { icon = "#", hl = "Number" },
|
Number = { icon = '#', hl = 'Number' },
|
||||||
Boolean = { icon = "⊨", hl = "Boolean" },
|
Boolean = { icon = '⊨', hl = 'Boolean' },
|
||||||
Array = { icon = "", hl = "Constant" },
|
Array = { icon = '', hl = 'Constant' },
|
||||||
Object = { icon = "⦿", hl = "Type" },
|
Object = { icon = '⦿', hl = 'Type' },
|
||||||
Key = { icon = "🔐", hl = "Type" },
|
Key = { icon = '🔐', hl = 'Type' },
|
||||||
Null = { icon = "NULL", hl = "Type" },
|
Null = { icon = 'NULL', hl = 'Type' },
|
||||||
EnumMember = { icon = "", hl = "Identifier" },
|
EnumMember = { icon = '', hl = 'Identifier' },
|
||||||
Struct = { icon = "𝓢", hl = "Structure" },
|
Struct = { icon = '𝓢', hl = 'Structure' },
|
||||||
Event = { icon = "🗲", hl = "Type" },
|
Event = { icon = '🗲', hl = 'Type' },
|
||||||
Operator = { icon = "+", hl = "Identifier" },
|
Operator = { icon = '+', hl = 'Identifier' },
|
||||||
TypeParameter = { icon = "𝙏", hl = "Identifier" },
|
TypeParameter = { icon = '𝙏', hl = 'Identifier' },
|
||||||
Component = { icon = "", hl = "Function" },
|
Component = { icon = '', hl = 'Function' },
|
||||||
Fragment = { icon = "", hl = "Constant" },
|
Fragment = { icon = '', hl = 'Constant' },
|
||||||
TypeAlias = { icon = " ", hl = "Type" },
|
TypeAlias = { icon = ' ', hl = 'Type' },
|
||||||
Parameter = { icon = " ", hl = "Identifier" },
|
Parameter = { icon = ' ', hl = 'Identifier' },
|
||||||
StaticMethod = { icon = " ", hl = "Function" },
|
StaticMethod = { icon = ' ', hl = 'Function' },
|
||||||
Macro = { icon = " ", hl = "Function" },
|
Macro = { icon = ' ', hl = 'Function' },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,32 +1,35 @@
|
|||||||
return {
|
return {
|
||||||
"stevearc/conform.nvim",
|
'stevearc/conform.nvim',
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
|
opts = {
|
||||||
config = function()
|
formatters_by_ft = {
|
||||||
local conform = require "conform"
|
sh = { 'shellharden', 'shfmt' },
|
||||||
|
bash = { 'shellharden', 'shfmt' },
|
||||||
conform.setup {
|
zsh = { 'shellharden', 'shfmt' },
|
||||||
formatters_by_ft = {
|
javascript = { 'prettier' },
|
||||||
javascript = { "prettier" },
|
typescript = { 'prettier' },
|
||||||
typescript = { "prettier" },
|
css = { 'prettier' },
|
||||||
javascriptreact = { "prettier" },
|
html = { 'prettier' },
|
||||||
typescriptreact = { "prettier" },
|
json = { 'prettier' },
|
||||||
svelte = { "prettier" },
|
yaml = { 'prettier' },
|
||||||
css = { "prettier" },
|
markdown = { 'markdownlint', 'prettier' },
|
||||||
html = { "prettier" },
|
graphql = { 'prettier' },
|
||||||
json = { "prettier" },
|
liquid = { 'prettier' },
|
||||||
yaml = { "prettier" },
|
lua = { 'stylua' },
|
||||||
markdown = { "prettier" },
|
python = { 'black', 'sort' },
|
||||||
graphql = { "prettier" },
|
},
|
||||||
liquid = { "prettier" },
|
formatters = {
|
||||||
lua = { "stylua" },
|
--[[ shfmt = {
|
||||||
python = { "sort", "black" },
|
prepend_args = { '-i', '6' },
|
||||||
},
|
}, ]]
|
||||||
format_on_save = {
|
},
|
||||||
lsp_fallback = true,
|
default_format_opts = {
|
||||||
async = false,
|
lsp_format = 'fallback',
|
||||||
timeout_ms = 1000,
|
},
|
||||||
},
|
format_on_save = {
|
||||||
}
|
lsp_format = 'fallback',
|
||||||
end,
|
async = false,
|
||||||
|
timeout_ms = 1000,
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,21 +1,25 @@
|
|||||||
return {
|
return {
|
||||||
"hiphish/rainbow-delimiters.nvim",
|
'hiphish/rainbow-delimiters.nvim',
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
|
main = 'rainbow-delimiters.setup',
|
||||||
opts = {
|
opts = {
|
||||||
strategy = {},
|
|
||||||
query = {},
|
|
||||||
highlight = {
|
highlight = {
|
||||||
"RainbowDelimiterCyan",
|
'RainbowDelimiterCyan',
|
||||||
"RainbowDelimiterBlue",
|
'RainbowDelimiterBlue',
|
||||||
"RainbowDelimiterGreen",
|
'RainbowDelimiterGreen',
|
||||||
"RainbowDelimiterViolet",
|
'RainbowDelimiterViolet',
|
||||||
"RainbowDelimiterYellow",
|
'RainbowDelimiterYellow',
|
||||||
"RainbowDelimiterRed",
|
'RainbowDelimiterRed',
|
||||||
"RainbowDelimiterOrange",
|
'RainbowDelimiterOrange',
|
||||||
|
},
|
||||||
|
query = {
|
||||||
|
[''] = 'rainbow-delimiters',
|
||||||
|
lua = 'rainbow-blocks',
|
||||||
|
help = 'rainbow-blocks',
|
||||||
|
query = function(bufnr)
|
||||||
|
local is_nofile = vim.bo[bufnr].buftype == 'nofile'
|
||||||
|
return is_nofile and 'rainbow-blocks' or 'rainbow-delimiters'
|
||||||
|
end,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
config = function(_, opts)
|
|
||||||
require("rainbow-delimiters.setup").setup(opts)
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,10 @@
|
|||||||
return {
|
return {
|
||||||
'gbprod/substitute.nvim',
|
'gbprod/substitute.nvim',
|
||||||
event = { 'BufReadPre', 'BufNewFile' },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
opts = {},
|
opts = {
|
||||||
}
|
highlight_substituted_text = {
|
||||||
|
enabled = true,
|
||||||
|
timer = 800,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
return {
|
|
||||||
-- does the same thing as git_files, but for yadm
|
|
||||||
'pschmitt/telescope-yadm.nvim',
|
|
||||||
dependencies = {
|
|
||||||
'nvim-telescope/telescope.nvim',
|
|
||||||
},
|
|
||||||
enabled = true,
|
|
||||||
event = 'VeryLazy',
|
|
||||||
|
|
||||||
config = function(_, opts)
|
|
||||||
local telescope = require('telescope')
|
|
||||||
|
|
||||||
telescope.setup(opts)
|
|
||||||
telescope.load_extension('yadm_files')
|
|
||||||
telescope.load_extension('git_or_files')
|
|
||||||
telescope.load_extension('git_or_yadm_files')
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
@@ -3,9 +3,11 @@ return {
|
|||||||
branch = '0.1.x',
|
branch = '0.1.x',
|
||||||
dependencies = {
|
dependencies = {
|
||||||
'nvim-lua/plenary.nvim',
|
'nvim-lua/plenary.nvim',
|
||||||
{ 'nvim-telescope/telescope-fzf-native.nvim', build = 'make' },
|
|
||||||
'nvim-tree/nvim-web-devicons',
|
'nvim-tree/nvim-web-devicons',
|
||||||
|
{ 'nvim-telescope/telescope-fzf-native.nvim', build = 'make' },
|
||||||
'folke/todo-comments.nvim',
|
'folke/todo-comments.nvim',
|
||||||
|
'pschmitt/telescope-yadm.nvim',
|
||||||
|
{ 'nvim-telescope/telescope-media-files.nvim', dependencies = 'nvim-lua/popup.nvim' },
|
||||||
},
|
},
|
||||||
event = 'VeryLazy',
|
event = 'VeryLazy',
|
||||||
config = function()
|
config = function()
|
||||||
@@ -51,9 +53,16 @@ return {
|
|||||||
},
|
},
|
||||||
extensions = {
|
extensions = {
|
||||||
fzf = {},
|
fzf = {},
|
||||||
|
media_files = {
|
||||||
|
find_cmd = 'rg',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
telescope.load_extension('fzf')
|
telescope.load_extension('fzf')
|
||||||
|
telescope.load_extension('media_files')
|
||||||
|
telescope.load_extension('yadm_files')
|
||||||
|
telescope.load_extension('git_or_files')
|
||||||
|
telescope.load_extension('git_or_yadm_files')
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,8 +15,4 @@ return {
|
|||||||
return buftype == 'terminal' or floating
|
return buftype == 'terminal' or floating
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
|
|
||||||
config = function(_, opts)
|
|
||||||
require('tint').setup(opts)
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
return {
|
return {
|
||||||
"christoomey/vim-tmux-navigator",
|
'christoomey/vim-tmux-navigator',
|
||||||
cmd = {
|
cmd = {
|
||||||
"TmuxNavigateLeft",
|
'TmuxNavigateLeft',
|
||||||
"TmuxNavigateDown",
|
'TmuxNavigateDown',
|
||||||
"TmuxNavigateUp",
|
'TmuxNavigateUp',
|
||||||
"TmuxNavigateRight",
|
'TmuxNavigateRight',
|
||||||
"TmuxNavigatePrevious",
|
'TmuxNavigatePrevious',
|
||||||
},
|
},
|
||||||
keys = {
|
keys = {
|
||||||
{ "<c-h>", "<cmd><C-U>TmuxNavigateLeft<cr>" },
|
{ '<c-h>', '<cmd><C-U>TmuxNavigateLeft<cr>' },
|
||||||
{ "<c-j>", "<cmd><C-U>TmuxNavigateDown<cr>" },
|
{ '<c-j>', '<cmd><C-U>TmuxNavigateDown<cr>' },
|
||||||
{ "<c-k>", "<cmd><C-U>TmuxNavigateUp<cr>" },
|
{ '<c-k>', '<cmd><C-U>TmuxNavigateUp<cr>' },
|
||||||
{ "<c-l>", "<cmd><C-U>TmuxNavigateRight<cr>" },
|
{ '<c-l>', '<cmd><C-U>TmuxNavigateRight<cr>' },
|
||||||
{ "<c-\\>", "<cmd><C-U>TmuxNavigatePrevious<cr>" },
|
{ '<c-\\>', '<cmd><C-U>TmuxNavigatePrevious<cr>' },
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,6 @@
|
|||||||
return {
|
return {
|
||||||
"folke/todo-comments.nvim",
|
'folke/todo-comments.nvim',
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
dependencies = { 'nvim-lua/plenary.nvim' },
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
|
opts = {},
|
||||||
config = function()
|
|
||||||
require("todo-comments").setup()
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -43,11 +43,11 @@ return {
|
|||||||
incremental_selection = {
|
incremental_selection = {
|
||||||
enable = true,
|
enable = true,
|
||||||
keymaps = {
|
keymaps = {
|
||||||
init_selection = '<C-space>',
|
init_selection = 'gnn',
|
||||||
node_incremental = '<C-space>',
|
node_incremental = 'grn',
|
||||||
scope_incremental = false,
|
scope_incremental = 'grc',
|
||||||
node_decremental = '<bs>',
|
node_decremental = '<bs>',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,10 +2,22 @@ return {
|
|||||||
'folke/trouble.nvim',
|
'folke/trouble.nvim',
|
||||||
dependencies = {
|
dependencies = {
|
||||||
'nvim-tree/nvim-web-devicons',
|
'nvim-tree/nvim-web-devicons',
|
||||||
'folke/todo-comments.nvim',
|
|
||||||
},
|
},
|
||||||
cmd = 'Trouble',
|
cmd = 'Trouble',
|
||||||
opts = {
|
opts = {
|
||||||
focus = false,
|
focus = false,
|
||||||
|
warn_no_results = false,
|
||||||
|
open_no_results = true,
|
||||||
|
auto_close = false,
|
||||||
|
auto_open = false,
|
||||||
|
auto_preview = true,
|
||||||
|
auto_refresh = true,
|
||||||
|
auto_jump = false,
|
||||||
|
restore = true,
|
||||||
|
follow = true,
|
||||||
|
indent_guides = true,
|
||||||
|
max_items = 200,
|
||||||
|
multiline = true,
|
||||||
|
pinned = false,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
return {
|
return {
|
||||||
'szw/vim-maximizer',
|
'szw/vim-maximizer',
|
||||||
event = { 'BufReadPre', 'BufNewFile' },
|
event = { 'BufReadPre', 'BufNewFile' },
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,18 @@
|
|||||||
return {
|
return {
|
||||||
'folke/which-key.nvim',
|
'folke/which-key.nvim',
|
||||||
|
dependencies = {
|
||||||
|
'nvim-tree/nvim-web-devicons',
|
||||||
|
},
|
||||||
event = 'VeryLazy',
|
event = 'VeryLazy',
|
||||||
init = function()
|
init = function()
|
||||||
vim.o.timeout = true
|
vim.o.timeout = true
|
||||||
vim.o.timeoutlen = 500
|
vim.o.timeoutlen = 800
|
||||||
end,
|
end,
|
||||||
opts = {
|
opts = {
|
||||||
preset = 'modern', -- may set this back to 'classic'
|
preset = 'modern', -- may set this back to 'classic'
|
||||||
sort = { 'local', 'order', 'group', 'alphanum', 'mod' },
|
sort = { 'local', 'order', 'group', 'case', 'alphanum', 'mod' },
|
||||||
|
expand = 2,
|
||||||
|
delay = 200,
|
||||||
notify = true,
|
notify = true,
|
||||||
win = {
|
win = {
|
||||||
title = true,
|
title = true,
|
||||||
@@ -21,6 +26,15 @@ return {
|
|||||||
enabled = true,
|
enabled = true,
|
||||||
suggestions = 20,
|
suggestions = 20,
|
||||||
},
|
},
|
||||||
|
presets = {
|
||||||
|
operators = true,
|
||||||
|
motions = true,
|
||||||
|
text_objects = true,
|
||||||
|
windows = true,
|
||||||
|
nav = true,
|
||||||
|
z = true,
|
||||||
|
g = true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user