Minimal, fast, and competitive‑programming friendly Neovim setup built on top of NvChad.
Install first:
- Neovim >= 0.9
- Git
- A Nerd Font (for icons) – e.g. FiraCode / JetBrainsMono Nerd Font
Optional (installed/managed automatically when configured): LSP servers, linters, formatters.
- NvChad core (theme system, statusline, bufferline, tree, telescope)
- Competitive Programming helpers (compile/run, test harness, optimization profile cycling, reusable terminal)
- Auto‑insert C++ template on new
*.cpp
file +cp
snippet - Dashboard (alpha.nvim) + Enhanced UI & command popup border feedback (noice.nvim)
- Diagnostics UI (trouble.nvim) & Quick Navigation (harpoon)
- Tasks (overseer.nvim) & Formatting/Linting (conform + nvim-lint + mason bridges)
- Snippets (LuaSnip + friendly-snippets + custom
cp
C++ template)
Guides: User Manual · Snippets · Motions
Dashboard (Alpha) | Editing (Normal) | Transparent UI |
---|---|---|
![]() |
![]() |
![]() |
backup_dir="$HOME/.config/nvim_backup_$(date +%s)" && \
mv ~/.config/nvim "$backup_dir" 2>/dev/null || true && \
mv ~/.local/share/nvim "$backup_dir-data" 2>/dev/null || true && \
mv ~/.cache/nvim "$backup_dir-cache" 2>/dev/null || true && \
git clone https://github.com/samonide/nvim ~/.config/nvim && \
nvim
mkdir -p ~/.config && \
git submodule add https://github.com/samonide/nvim ~/.config/nvim || git clone https://github.com/samonide/nvim ~/.config/nvim && \
nvim
TMPDIR=$(mktemp -d)
git clone https://github.com/samonide/nvim "$TMPDIR/nvim"
XDG_CONFIG_HOME="$TMPDIR" XDG_DATA_HOME="$TMPDIR/data" XDG_STATE_HOME="$TMPDIR/state" XDG_CACHE_HOME="$TMPDIR/cache" nvim
- Launch Neovim (
nvim
). - Let
lazy.nvim
install plugins. - Open the dashboard (auto) or run
:Alpha
. - Press
<leader>ch
(NvChad cheatsheet) or<leader>wK
(WhichKey) to explore. - For C++: create
main.cpp
, typecp<Tab>
for full template orcb<Tab>
for simple boilerplate, then<leader>cr
to compile & run.
Path | Purpose |
---|---|
init.lua |
Entry point: bootstraps plugin manager + mappings |
lua/chadrc.lua |
NvChad UI & theme overrides |
lua/options.lua |
Core editor options & shell override |
lua/mappings.lua |
All custom keymaps (CP + tooling) |
lua/plugins/ |
Additional plugin specs |
lua/configs/ |
Per-plugin configuration modules |
guide/USERMANUAL.md |
Comprehensive user & keymap manual |
guide/SNIPPETS.md |
Competitive programming snippets reference |
guide/MOTIONS.md |
Beginner Vim motions & operators cheat sheet |
Feature | Keymaps |
---|---|
Compile & Run | <leader>cr / <leader>cb |
Run last binary | <leader>ce |
Run tests (tests/*.in) | <leader>ctt |
Run with I/O files | <C-A-n> (NEW: input.txt → output.txt) |
Optimization profile cycle | <leader>co |
Redirect input.txt | <leader>ct |
Open input.txt | <leader>ci |
Templates | cp (full competitive), cb (simple boilerplate) |
- Add more LSP servers in
configs/lspconfig.lua
& rerun Neovim. - Extend Treesitter parsers in
configs/treesitter.lua
. - Add formatters/linters via conform / nvim-lint config files.
- Place new snippets with LuaSnip in a dedicated module or VSCode-style JSON.
cd ~/.config/nvim
git pull --rebase
:Lazy sync
Commit lazy-lock.json
to lock plugin versions.
To update just plugins without git changes: inside Neovim run :Lazy sync
(or :Lazy check
to inspect outdated first).
Issue | Check |
---|---|
Missing highlight | :TSInstall <lang> |
Formatter not running | <leader>fm / check filetype mapping |
LSP inactive | :LspInfo / :Mason |
Test harness mismatch | Ensure tests/*.out files exist |
Icons wrong | Install & select a Nerd Font in terminal |
Category | Plugin | Description |
---|---|---|
🚀 Core | lazy.nvim | Modern plugin manager |
nvim-tree | File explorer tree | |
telescope.nvim | Fuzzy finder & picker | |
which-key.nvim | Keybinding helper UI | |
nvim-cmp | Completion engine | |
🎨 Syntax | nvim-treesitter | Syntax highlighting & parsing |
nvim-lspconfig | LSP client configurations | |
mason.nvim | LSP/tool installer | |
mason-lspconfig.nvim | Mason ↔ LSP bridge | |
✨ Format | conform.nvim | Code formatting engine |
nvim-lint | Async linting | |
mason-conform.nvim | Mason ↔ Conform bridge | |
mason-nvim-lint | Mason ↔ Lint bridge | |
🎯 UI/UX | alpha-nvim | Dashboard & startup screen |
noice.nvim | Enhanced cmdline/messages UI | |
nvim-notify | Beautiful notifications | |
trouble.nvim | Diagnostics & quickfix UI | |
harpoon | Quick file navigation marks | |
🔧 Tools | overseer.nvim | Task runner & build system |
telescope-fzf-native | Native FZF sorter (faster) | |
LuaSnip | Snippet engine | |
friendly-snippets | Community snippet collection |
See LICENSE
.
Happy hacking! For deep usage details, read the full manual in guide/USERMANUAL.md.