| Key | Action |
|---|---|
<Space> |
Leader key |
<Esc> |
Clear search highlight |
<C-h/j/k/l> |
Navigate between windows |
<S-h> / <S-l> |
Previous/Next buffer |
<leader>w |
Save file |
<leader>q |
Quit |
| Key | Action |
|---|---|
<leader>e |
Toggle file explorer (Neo-tree) |
<leader>sf |
Search/Find files |
<leader>sg |
Live grep (search in files) |
<leader>sw |
Search current word |
<leader>sb |
Search buffers |
<leader>sh |
Search help |
<leader>/ |
Fuzzy search in current buffer |
<leader><leader> |
Find existing buffers |
| Key | Action |
|---|---|
gd |
Go to definition |
gr |
Go to references |
gI |
Go to implementation |
gD |
Go to declaration |
K |
Hover documentation |
<leader>ca |
Code actions |
<leader>rn |
Rename symbol |
<leader>D |
Type definition |
<leader>ds |
Document symbols |
<leader>ws |
Workspace symbols |
[d / ]d |
Previous/Next diagnostic |
<leader>e |
Open diagnostic float |
<leader>dl |
Open diagnostics list |
| Key | Action |
|---|---|
<leader>gg |
Open LazyGit |
<leader>hs |
Stage hunk |
<leader>hr |
Reset hunk |
<leader>hS |
Stage buffer |
<leader>hR |
Reset buffer |
<leader>hp |
Preview hunk |
<leader>hb |
Blame line |
<leader>hd |
Diff this |
[c / ]c |
Previous/Next git hunk |
| Key | Action |
|---|---|
<F5> |
Start/Continue debugging |
<F1> |
Step into |
<F2> |
Step over |
<F3> |
Step out |
<F7> |
Toggle debug UI |
<leader>b |
Toggle breakpoint |
<leader>B |
Set conditional breakpoint |
| Key | Action |
|---|---|
gcc |
Toggle line comment |
gc (visual) |
Toggle comment selection |
<C-n> |
Next completion item |
<C-p> |
Previous completion item |
<C-y> |
Confirm completion |
<Tab> |
Next completion/snippet |
<S-Tab> |
Previous completion/snippet |
<leader>nf |
Generate function docstring |
<leader>nc |
Generate class docstring |
| Key | Action |
|---|---|
J |
Move line down |
K |
Move line up |
| Key | Action |
|---|---|
<C-d> |
Scroll down (centered) |
<C-u> |
Scroll up (centered) |
n / N |
Next/Previous search (centered) |
- Open a Python project:
cd ~/my-python-project
nix-shell
nvim .-
Open file explorer:
<leader>e -
Find files:
<leader>sf
- Jump to definition:
gd - Find references:
gr - View documentation:
K - See all symbols:
<leader>ds
- Auto-completion works automatically as you type
- Format code: Happens automatically on save
- Rename variable:
<leader>rn - Quick fix:
<leader>ca
- Set breakpoints:
<leader>b - Start debugging:
<F5 - Step through code:
<F1>,<F2>,<F3> - View variables and stack in debug UI
- Open LazyGit:
<leader>gg - Stage hunks:
<leader>hs - View git blame:
<leader>hb - Navigate changes:
[cand]c
Edit the colorscheme section in init.lua:
{
"folke/tokyonight.nvim",
priority = 1000,
config = function()
vim.cmd.colorscheme("tokyonight-night")
-- Options: tokyonight-night, tokyonight-storm, tokyonight-day, tokyonight-moon
end,
},Other popular colorschemes:
catppuccin/nvim- Catppuccin themerebelot/kanagawa.nvim- Kanagawa themeEdenEast/nightfox.nvim- Nightfox theme
Add to the servers table in the LSP configuration:
local servers = {
pyright = { ... },
ruff_lsp = { ... },
lua_ls = { ... },
-- Add more servers here
jsonls = {}, -- JSON
yamlls = {}, -- YAML
}Edit the conform.nvim configuration:
formatters_by_ft = {
python = { "isort", "black" },
lua = { "stylua" },
-- Add more formatters
}If plugins don't install automatically:
- Open Neovim
- Run
:Lazy sync - Wait for all plugins to install
- Restart Neovim
- Check LSP status:
:LspInfo - Ensure Mason installed servers:
:Mason - Install manually if needed:
:MasonInstall pyright ruff-lsp
If you see treesitter parsing errors:
- Update parsers:
:TSUpdate - Check installed parsers:
:TSInstallInfo - Install specific parser:
:TSInstall python
Install lazygit system-wide or add to shell.nix:
buildInputs = [
python3
neovim
lazygit # Add this
];- Neovim >= 0.9.0
- Git
- Python 3
- Node.js (for some LSP servers)
- ripgrep (for Telescope live grep)
- fd (optional, for better file finding)
- lazygit (optional, for git UI)
:Tutor- Built-in Neovim tutorial:help- Access help documentation:checkhealth- Verify Neovim setup:Lazy- Plugin manager UI:Mason- LSP server manager UI