111 lines
2.4 KiB
Lua
111 lines
2.4 KiB
Lua
require('legendary').setup({
|
|
default_opts = {
|
|
keymaps = { silent = true },
|
|
commands = {},
|
|
autocmds = {},
|
|
},
|
|
keymaps = {
|
|
{
|
|
'<Leader>p',
|
|
function()
|
|
require("legendary").find()
|
|
end,
|
|
description = 'legendary keymaps',
|
|
mode = { 'n', 'x', 'i' }
|
|
},
|
|
{
|
|
'<F2>',
|
|
':tabnew .<CR>',
|
|
description = 'Open a new tab',
|
|
},
|
|
{
|
|
'<C-F2>',
|
|
':vsplit .<CR>',
|
|
description = 'Open a new vertical split',
|
|
},
|
|
{
|
|
'<S-F2>',
|
|
':split .<CR>',
|
|
description = 'Open a new horizontal split',
|
|
},
|
|
{
|
|
'<Space>g',
|
|
':lua _lazygit_toggle()<CR>',
|
|
description = 'Open lazygit',
|
|
},
|
|
{
|
|
'<leader>a',
|
|
'"ayiw',
|
|
description = 'Word under cursor into register a',
|
|
},
|
|
{
|
|
'<space>x',
|
|
'za',
|
|
description = 'Toggle fold',
|
|
},
|
|
{
|
|
'<c-n>',
|
|
'<Plug>(YankyCycleForward)',
|
|
description = 'Yanky cycle forward',
|
|
},
|
|
{
|
|
'<c-p>',
|
|
'<Plug>(YankyCycleBackward)',
|
|
description = 'Yanky cycle backward',
|
|
},
|
|
{
|
|
'<leader>s',
|
|
':AerialToggle<CR>',
|
|
description = 'Symbols outline',
|
|
},
|
|
},
|
|
commands =
|
|
{
|
|
{
|
|
':Octo pr list<CR>',
|
|
description = 'Github list PRs',
|
|
},
|
|
{
|
|
':Octo pr checkout<CR>',
|
|
description = 'Github checkout PR',
|
|
},
|
|
{
|
|
':Octo pr browser<CR>',
|
|
description = 'Github open PR in browser',
|
|
},
|
|
{
|
|
':set guifont=JetBrainsMonoNL\\ NF:h12<CR>',
|
|
description = 'Big font size',
|
|
},
|
|
{
|
|
':set guifont=JetBrainsMonoNL\\ NF:h9<CR>',
|
|
description = 'Reset font size',
|
|
},
|
|
{
|
|
':CMake build_all<CR>',
|
|
description = 'CMake build all',
|
|
},
|
|
{
|
|
':CMake configure<CR>',
|
|
description = 'CMake configure',
|
|
},
|
|
{
|
|
':CMake select_target<CR>',
|
|
description = 'CMake select target',
|
|
},
|
|
{
|
|
':CMake clear_cache<CR>',
|
|
description = 'CMake clear cache',
|
|
},
|
|
{
|
|
':LuaSnipListAvailable<CR>',
|
|
description = 'List snippets',
|
|
},
|
|
{
|
|
":lua require('telescope.builtin').live_grep({ prompt_title = 'find string in open buffers...', grep_open_files = true })<CR>",
|
|
description = 'Search in open files',
|
|
},
|
|
|
|
}
|
|
})
|