Skip to content

cadic2603/vimrc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vimrc

My personal Vim configuration with 54 plugins covering LSP, completion, debugging, testing, Git, fuzzy finding, snippets, and more.

Quick Install

git clone https://github.com/cadic2603/vimrc.git ~/vimrc
cd ~/vimrc
./install.sh

The script handles everything: system dependencies, Nerd Font, vim-plug, plugin installation, and backup of your existing .vimrc.

Supported systems

  • Debian/Ubuntu (apt)
  • Fedora/RHEL (dnf)
  • Arch Linux (pacman)
  • macOS (Homebrew)

Manual install

If you prefer to install manually:

# Copy config
cp .vimrc ~/.vimrc

# Install vim-plug (auto-installs on first vim launch, or manually):
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
  https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim

# Open vim and install plugins
vim +PlugInstall

Prerequisites

  • Vim 9.0+ (the install script auto-builds from source if your distro ships an older version)
  • git, curl, unzip
  • ripgrep (for :Rg search)
  • Node.js (for GitHub Copilot)
  • Nerd Font (for devicons and powerline symbols)
  • xclip or xsel (for system clipboard on Linux)

Plugins

Git

Plugin Description
vim-fugitive Git commands (:Git, :Git blame, etc.)
vim-gitgutter Git diff signs in the gutter
conflict-marker.vim Highlight and resolve git conflict markers
gv.vim Git log browser (:GV)

Navigation

Plugin Description
NERDTree File explorer sidebar
fzf.vim Fuzzy finder (files, buffers, ripgrep)
vista.vim Code outline / symbol viewer (LSP-powered)
vim-sneak Two-character motion with labels

LSP, Completion & Snippets

Plugin Description
vim-lsp LSP client (definition, hover, rename, references)
vim-lsp-settings Auto-install language servers
vim-lsp-ale Bridge vim-lsp diagnostics through ALE
ALE Async linting and formatting
asyncomplete.vim Async autocompletion
asyncomplete-lsp.vim LSP completion source
asyncomplete-buffer.vim Buffer word completion source
asyncomplete-file.vim File path completion source
vim-vsnip Snippet engine (VSCode format)
friendly-snippets Snippet collection
copilot.vim GitHub Copilot AI completion

Editing

Plugin Description
vim-surround Surround text with brackets/quotes/tags
vim-commentary Toggle comments (gcc / gc)
lexima.vim Auto-close brackets and quotes
vim-repeat Dot-repeat for plugin mappings
vim-abolish Smart substitution and case coercion
vim-unimpaired Bracket mappings (]q, [b, ]e, etc.)
targets.vim Extended text objects (arguments, separators)
vim-matchup Enhanced % matching for language keywords
vim-visual-multi Multiple cursors
emmet-vim HTML/CSS expansion
traces.vim Live preview for :s substitutions
vim-better-whitespace Highlight/strip trailing whitespace

Debugging & Testing

Plugin Description
vimspector DAP debugger (same adapters as VS Code)
vim-test Test runner (:TestNearest, :TestFile, :TestSuite)
vim-dispatch Async build/dispatch with quickfix

UI & Appearance

Plugin Description
vim-airline Status/tabline (theme: raven)
vim-devicons File-type icons
onedark.vim One Dark color scheme
indentLine Indent level visualization
vim-highlightedyank Flash yanked region

Utilities

Plugin Description
vim-eunuch Unix helpers (:Delete, :Rename, :SudoWrite)
vim-floaterm Terminal management
vim-obsession Continuous session saving
vim-startify Start screen with recent files
vim-which-key Keybinding discovery popup
undotree Undo tree visualization
vim-bbye Close buffers without breaking layout
vim-qf Quickfix list enhancements
vim-sleuth Automatic indent detection
editorconfig-vim EditorConfig support
vim-polyglot Language pack (syntax, indent, ftdetect)
markdown-preview.nvim Live markdown preview in browser (:MarkdownPreview)

Language Support

The install script sets up linters, formatters, and language servers automatically.

Language LSP Server (auto-installed) Linter Formatter Fix on Save
Go gopls golangci-lint gofmt + goimports Yes
Rust rust-analyzer cargo rustfmt Yes
TypeScript / TSX typescript-language-server eslint eslint + prettier Yes
JavaScript / JSX typescript-language-server eslint eslint + prettier Yes
Python pylsp or pyright flake8, mypy black, isort Yes
YAML yaml-language-server yamllint prettier Yes
Markdown marksman markdownlint prettier Yes
JSON json-languageserver jsonlint prettier Yes
HTML htmlhint prettier Yes
CSS stylelint prettier Yes
Shell/Bash shellcheck shfmt Yes

LSP servers are auto-installed by vim-lsp-settings when you first open a file of that type — just run :LspInstallServer when prompted.

Markdown preview: open a .md file and run :MarkdownPreview to see a live preview in your browser.

Key Mappings

General

Key Mode Action
Y Normal Yank to end of line
<leader><space> Normal Clear search highlighting
Ctrl+H/J/K/L Normal Navigate between splits
<leader>q Normal Close buffer (keep window layout)

File Navigation

Key Mode Action
<leader>e Normal Toggle NERDTree
Ctrl+P Normal Fuzzy find files
<leader>b Normal Fuzzy find buffers
<leader>/ Normal Ripgrep search
F8 Normal Toggle code outline (Vista)

LSP

Key Mode Action
gd Normal Go to definition
gD Normal Go to declaration
gr Normal Find references
gi Normal Go to implementation
gy Normal Go to type definition
K Normal Hover documentation
<leader>rn Normal Rename symbol
<leader>ca Normal Code action
[g / ]g Normal Previous/next diagnostic

Completion & Snippets

Key Mode Action
Tab / S-Tab Insert Navigate completion popup
Enter Insert Accept completion
Ctrl+L Insert Expand snippet
Ctrl+J / Ctrl+K Insert Jump to next/previous snippet tabstop

Debugging (Vimspector)

Key Mode Action
<leader>dc Normal Continue
<leader>db Normal Toggle breakpoint
<leader>dB Normal Conditional breakpoint
<leader>ds Normal Step over
<leader>di Normal Step into
<leader>do Normal Step out
<leader>dr Normal Restart
<leader>dx Normal Stop

Testing (vim-test)

Key Mode Action
<leader>tn Normal Test nearest
<leader>tf Normal Test file
<leader>ts Normal Test suite
<leader>tl Normal Test last

Other

Key Mode Action
F5 Normal Toggle undo tree
F12 Normal/Terminal Toggle terminal (floaterm)
gcc Normal Toggle comment on line
gc Visual Toggle comment on selection
s{char}{char} Normal Sneak — jump to two-character match
crs / crc / cru Normal Coerce to snake_case / camelCase / UPPER_CASE

Settings

  • Theme: One Dark + Airline raven
  • Font: DroidSansM Nerd Font 11
  • Indentation: 2 spaces (auto-detected per file by vim-sleuth)
  • Line numbers: Absolute
  • Search: Incremental, case-insensitive unless uppercase used (smartcase)
  • Mouse: Enabled in all modes
  • Clipboard: System clipboard (unnamedplus)
  • Undo: Persistent across sessions (~/.vim/undodir/)
  • Update time: 300ms (for fast gutter/diagnostic updates)
  • Completion: menuone,noinsert,noselect,popup

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors