-- Plugins: Editor -- https://github.com/rafi/vim-config local is_windows = vim.loop.os_uname().sysname == 'Windows_NT' return { ----------------------------------------------------------------------------- { 'ggandor/leap.nvim', -- stylua: ignore keys = { { 'gl', '(leap-forward-to)', mode = { 'n', 'x', 'o' }, desc = 'Leap forward to' }, { 'gL', '(leap-backward-to)', mode = { 'n', 'x', 'o' }, desc = 'Leap backward to' }, { 'wl', '(leap-from-window)', mode = { 'n', 'x', 'o' }, desc = 'Leap to windows' }, }, config = function () local leap = require('leap') leap.opts.case_sensitive = false leap.opts.safe_labels = { 'f', 'n', 'u', 't', 'g', 'ö', 'w', 'b', 'm' } leap.opts.labels = { 'a', 's', 'f', 'n', 'j', 'k', 'r', 'e', 'r', 'm', 'ö', 'b', 'v', 'u', 'z', 'w', '2', '3', '4', '5', '6', '7', '8', '9' } end, }, ----------------------------------------------------------------------------- -- NOTE: THIS SECTION CONTAINS THE PREFIXES! { 'folke/which-key.nvim', event = 'VeryLazy', opts = { icons = { separator = ' 󰁔 ' }, window = { winblend = 0 }, defaults = { mode = { 'n', 'v' }, [';'] = { name = '+telescope' }, [';d'] = { name = '+lsp/todo' }, ['g'] = { name = '+goto' }, ['gz'] = { name = '+surround' }, [']'] = { name = '+next' }, ['['] = { name = '+prev' }, ['b'] = { name = '+buffer' }, ['c'] = { name = '+code' }, ['g'] = { name = '+git' }, ['h'] = { name = '+hunks' }, ['S'] = { name = '+search' }, ['t'] = { name = '+toggle/tools' }, ['u'] = { name = '+ui' }, ['x'] = { name = '+diagnostics/quickfix' }, ['z'] = { name = '+notes' }, ['w'] = { name = '+window' }, ['f'] = { name = '+formatting' }, ['m'] = { name = '+marks/misc' }, ['md'] = { name = '+line-diffs' }, }, }, config = function(_, opts) local wk = require('which-key') wk.setup(opts) wk.register(opts.defaults) end, }, ----------------------------------------------------------------------------- { 'folke/todo-comments.nvim', dependencies = 'nvim-telescope/telescope.nvim', -- stylua: ignore keys = { { ']t', function() require('todo-comments').jump_next() end, desc = 'Next todo comment' }, { '[t', function() require('todo-comments').jump_prev() end, desc = 'Previous todo comment' }, { 'dt', 'TodoTelescope', desc = 'todo' }, { 'xt', 'TodoTrouble', desc = 'Todo (Trouble)' }, { 'xT', 'TodoTrouble keywords=TODO,FIX,FIXME', desc = 'Todo/Fix/Fixme (Trouble)' }, { 'St', 'TodoTelescope', desc = 'Todo' }, { 'ST', 'TodoTelescope keywords=TODO,FIX,FIXME', desc = 'Todo/Fix/Fixme' }, }, opts = { signs = false }, }, }