Magictt provides a comprehensive set of keybindings for efficient Neovim navigation and editing. All keymaps are configured in lua/magictt/core/keymaps.lua.
Leader Key
The leader key is set to Space :
All keybindings that start with <leader> use the space bar as the prefix.
General Keymaps
Insert Mode
Keymap Action Description jk<ESC>Exit insert mode (alternative to ESC)
File Navigation & UI
Keymap Action Description <leader>pv:ExOpen file explorer (netrw) <leader>mm:MasonOpen Mason package manager <leader>ln:LazyOpen Lazy plugin manager
Search
Keymap Action Description <leader>nh:nohlClear search highlights
Number Operations
Keymap Action Description <leader>+<C-a>Increment number under cursor <leader>-<C-x>Decrement number under cursor
Window Management
Efficiently manage split windows:
Keymap Action Description <leader>sv<C-w>vSplit window vertically <leader>sh<C-w>sSplit window horizontally <leader>se<C-w>=Make splits equal size <leader>sx:closeClose current split
Combine window splits with the built-in window navigation commands (<C-w>h/j/k/l) to move between splits efficiently.
Tab Management
Manage tabs for organizing multiple buffers:
Keymap Action Description <leader>to:tabnewOpen new tab <leader>tx:tabcloseClose current tab <leader>tn:tabnGo to next tab <leader>tp:tabpGo to previous tab <leader>tf:tabnew %Open current buffer in new tab
LSP Keymaps
These keymaps are automatically configured when an LSP server attaches to a buffer. They are defined in lua/magictt/lsp.lua.
Code Navigation
Keymap Action Description gRTelescope LSP references Show all references to symbol under cursor gDGo to declaration Jump to declaration gdGo to definition Jump to definition giTelescope LSP implementations Show all implementations gtTelescope LSP type definitions Show type definitions
Code Actions & Refactoring
Keymap Modes Action Description <leader>caNormal, Visual Code action Show available code actions <leader>rnNormal Rename Smart rename symbol
Diagnostics
Keymap Action Description <leader>DTelescope diagnostics Show all diagnostics for current buffer <leader>dOpen float Show diagnostics for current line [dJump to previous Go to previous diagnostic ]dJump to next Go to next diagnostic
Documentation
Keymap Action Description KHover Show documentation for symbol under cursor
LSP Control
Keymap Action Description <leader>rs:LspRestartRestart LSP server
LSP keymaps are only available in buffers where an LSP server is attached. For example, gd (go to definition) will only work in files with language server support.
Keymap Categories Summary
General Basic editing, navigation, and UI controls
Window Management Create, resize, and navigate split windows
Tab Management Organize work across multiple tabs
LSP Features Code intelligence, navigation, and refactoring
Customizing Keymaps
To add your own keymaps, edit lua/magictt/core/keymaps.lua:
local keymap = vim . keymap
-- Example: Add a custom keymap
keymap . set ( "n" , "<leader>w" , ":w<CR>" , { desc = "Save file" })
Keymap function signature:
keymap . set ( mode , lhs , rhs , opts )
mode : “n” (normal), “i” (insert), “v” (visual), or for multiple
lhs : The key combination to trigger
rhs : The action to perform
opts : Options table (include desc for documentation)
Vim Options Core Vim settings and behavior
LSP Setup Language server configuration