1. Custom Core Bindings

KeybindModeDescription
jk or kjInsertEscape to Normal mode
;Normal, VisualMap to : (Command line)
:Normal, VisualMap to ; (Repeat last f/F/t/T motion)
LNormalSelect to end of line (vg_)
<C-u>NormalScroll page UP and center cursor (zz)
<C-d>NormalScroll page DOWN and center cursor (zz)
{NormalJump paragraph UP and center cursor
}NormalJump paragraph DOWN and center cursor
GNormalGo to end of file and center cursor
n / NNormalNext/Prev search match (kept centered)
gd / grNormalGo to definition / references (kept centered)
<C-o>NormalJump back in jump list (kept centered)
<leader>sNormalSearch and replace the word under the cursor
<C-r>VisualReplace all selected text (prompts for replacement)

2. Searching & Code Navigation (Snacks / Telescope)

KeybindAction
<leader>/Search (grep) text across all project files (uses ripgrep)
<leader>sgOpen live grep search dialog
<leader>swGrep search for the word under the cursor
<leader>sRResume the last search
<leader><space>Find files by name (uses fd under the hood)
<leader>ffSearch/find files in project directory
<leader>ssSearch document symbols (variables, functions)
<leader>llToggle lsp_lines (inline diagnostics)

3. File Explorer (mini.files)

  • Toggle current file: <leader>e
  • Toggle current working directory (cwd): <leader>E

Inside the mini.files pane:

  • l or <CR>: Open directory / File
  • h or -: Go up to parent directory
  • = : Synchronize changes (creates, renames, deletes files on disk)
  • <BS>: Reset view
  • g?: Show help
  • < / >: Trim left / right

4. Debugger (nvim-dap)

KeybindAction
<leader>dtToggle breakpoint
<leader>dcContinue execution
<leader>diStep Into
<leader>doStep Over
<leader>duStep Out
<leader>drOpen REPL
<leader>dlRun Last debugging session
<leader>dbList all Breakpoints
<leader>dqTerminate session and close UI
<leader>deSet exception breakpoints (all)

5. Terminal Control (toggleterm)

  • Toggle default floating terminal: <C-\>
KeybindAction
<leader>tfToggle Floating Terminal
<leader>tvToggle Vertical Terminal
<leader>thToggle Horizontal Terminal

6. Harpoon (Quick File Switching)

  • <leader>A – Add current file to Harpoon list
  • <leader>a – Open Harpoon quick menu
KeybindAction
<C-h>Jump to marked file 1
<C-t>Jump to marked file 2
<C-n>Jump to marked file 3
<C-s>Jump to marked file 4

7. AI Assistant (avante.nvim)

KeybindAction
<leader>asAsk Avante (opens sidebar chat)
<leader>aeEdit current file or selected block
<leader>aaApply generated code suggestions
<leader>arRefresh sidebar chat
<leader>aqClose sidebar chat
<leader>atToggle Avante sidebar
<Tab>Accept inline ghost text (Insert Mode)
<S-Tab>Dismiss inline ghost text (Insert Mode)

8. Compiler Bindings

  • <C-b><C-o> – Open Compiler UI
  • <C-b><C-b> – Re-run/Redo compiler command
  • <C-b><C-t> – Toggle compiler results window
  • <leader>qj – Go to next item in Quickfix list
  • <leader>qk – Go to previous item in Quickfix list

9. Essential Vim Motions & Editing Tricks

Commenting

  • gcc – Comment/uncomment the current line.
  • gc (in Visual Mode) – Comment/uncomment the selected block of code.
  • gcap – Comment the entire paragraph.

Text Objects (The action + inside/around + object rule)

Operate on code blocks directly without manual selection:

  • ci"Change inside double quotes (deletes content and enters Insert Mode).
  • da)Delete around parenthesis (deletes contents and the parentheses).
  • yi{Yank (copy) inside curly braces.
  • caTChange around HTML/XML tags.

Visual Block Mode (Multi-line editing)

Useful for inserting characters (like comment markers) across multiple lines:

  1. Move cursor to the start.
  2. Press <C-v> to enter Visual Block Mode.
  3. Move down/up to select lines.
  4. Press I (capital I) to enter insert mode at the front.
  5. Type your edits (e.g., # or // ).
  6. Press <Esc> to propagate changes across all lines.