README.md
July 14, 2026 ยท View on GitHub
homegrown.nvim is a collection of modular Neovim plugins and utility commands extracted from nvim2k that replaces desired functionalities from well known plugins.
โจ Features
- Bracket Navigation (
bracket_nav): Quick native mappings ([d,]b,[x, etc.) for diagnostics, quickfix, buffers, windows, conflict markers, and blank lines. (Replaces mini.bracketed) - Color Highlighter (
highlighter): A lightweight, automatic text highlighter for Hex/RGB/RGBA/HSL/HSLA color codes. (Replaces ccc.nvim) - Clipboard Utilities (
copy): Clean commands for copying relative/absolute paths, line numbers, file names, and GitHub/GitLab repository URLs. (Replaces gitlinker.nvim) - Markdown Preview (
md_preview): browser-based live-sync preview for markdown buffers without heavy dependencies. (Replaces markdown-preview.nvim) - Smart Autopairs (
pairs): Zero-dependency automatic completion and deletion for brackets, quotes, and HTML tags. (Replaces mini.pairs + nvim-ts-autotag) - Search & Replace (
replace): Project-wide search and replace via ripgrep and the quickfix list. (Replaces nvim-spectre) - Asynchronous Runner (
runner): Quick runner that executes visual selections or complete buffers in python, ruby, node, typescript, go, etc. (Replaces sniprun) - Terminal Layouts (
terminal): Shortcuts to toggle split, floating, and tabbed terminal buffers powered bysnacks.nvim. (Replaces termim) - Vim/Tmux split integration (
tmux): Seamless navigation across split editor panes and Tmux windows. (Replaces navigator.nvim) - Navigation, Ranger, and Git commands (
dir): Project RootDir directory swapper, Ranger Picker floating window, and shell-based background Git helper. (Lightweight replacement for heavy file managers/trees) - Dynamic Autotiling (
tiling): Dynamically split windows horizontally or vertically depending on the focused window aspect ratio when opening a file. (Lightweight replacement for complex layout managers)
โก Setup
โ๏ธ Requirements
- Neovim >= 0.9.0
- snacks.nvim (optional, for
terminalanddirmodules) - ripgrep (for
replacemodule) - ranger (optional, for
:RangerPickerindirmodule)
๐ป Installation
Install homegrown.nvim using your preferred package manager (e.g. lazy.nvim) and configure it with your desired options:
{
"2KAbhishek/homegrown.nvim",
opts = {
-- Pass a boolean to enable a module with default options
highlighter = true, -- Enable ColorHighlighterToggle command
copy = true, -- Enable clipboard copy utilities (including CopyGitUrl)
md_preview = true, -- Enable MDPreview command
pairs = true, -- Enable zero-dependency autopairs
replace = true, -- Enable project search & replace
runner = true, -- Enable async code runner command
terminal = true, -- Enable Snacks-based terminal commands (needs snacks.nvim)
tmux = true, -- Enable seamless vim/tmux navigation
dir = true, -- Enable RootDir, RangerPicker, and background Git commands
-- Or pass a table to customize specific configuration options
bracket_nav = {
enabled = true,
blank_lines = false, -- Disable [Space / ]Space mappings
},
tiling = {
enabled = true,
split_ratio = 1.8, -- Override default split ratio of 2.0
},
runner = {
enabled = true,
interpreters = {
rust = "cargo run", -- Add support for Rust code execution
}
},
pairs = {
enabled = true,
tag_filetypes = {
xml = true, -- Enable tag-closing in XML files
}
}
}
}
Or install it and load individual modules manually:
-- Initialize only the autopairs
require("homegrown.pairs").setup()
-- Initialize only the code runner
require("homegrown.runner").setup()
๐ Usage
1. Bracket Navigation (bracket_nav)
[d/]d: Previous/Next Diagnostic[q/]q: Previous/Next Quickfix[Q/]Q: First/Last Quickfix item[b/]b: Previous/Next Buffer[B/]B: First/Last Buffer[w/]w: Previous/Next Window[j/]j: Previous/Next Jump (changelist)[x/]x: Previous/Next Git conflict marker (<<<<<<<,=======,>>>>>>>)[<space>/]<space>: Insert blank line above/below without moving the cursor
2. Color Highlighter (highlighter)
- Run
:ColorHighlighterToggleto enable/disable. - Automatically adjusts text foreground color for contrast. Skips large buffers.
3. Clipboard Copy utilities (copy)
:CopyGitUrl- Copy lines/file GitHub URL to clipboard (supports visual line ranges):CopyRelativePath/:CopyAbsolutePath- Copy file path to clipboard:CopyRelativePathWithLine/:CopyAbsolutePathWithLine- Copy file path with current line number:CopyFileName- Copy current file name to clipboard
4. Markdown Preview (md_preview)
- Run
:MDPreviewto generate a temp HTML file and launch the preview.
5. Autopairs (pairs)
- Automatically closes brackets
(),[],{}and quotes"",'',. - Automatically closes HTML/XML tags in supported filetypes (
html,vue,svelte,react, etc.). - Smart backspace: deleting an open bracket deletes its closing pair if empty.
6. Search & Replace (replace)
- Run
:Replaceor:Replace <pattern>.
7. Code Runner (runner)
- Run
:Runnerto execute visual selection or buffer. - Supports Python, Ruby, Lua, Node (JavaScript), ts-node (TypeScript), Go, Bash, Elixir, and Java.
8. Terminal wrappers (terminal)
:Fterm: Floating terminal:Sterm: Split terminal (bottom):Vterm: Vertical split terminal (right):Tterm: Terminal in current buffer
9. Tmux Split Navigation (tmux)
- Navigate splits/panes using
<C-h>,<C-j>,<C-k>,<C-l>.
10. Navigation, Ranger, and Git commands (dir)
:RootDir- Change local directory to the project/Git root:RangerPicker- Floating Ranger file picker window (requiresrangerandsnacks.nvim):Git <args>- Run background git command and notify output
11. Dynamic Autotiling (tiling)
Splits the current window dynamically in the optimal direction based on its aspect ratio.
:AutoTile <file>- Split current window dynamically and open<file>(vertical split if the window is wide, horizontal split if it is tall):AutoTile- Split the current buffer dynamically in the optimal direction (vertical if wide, horizontal if tall)
๐๏ธ What's Next
Planning to add more helper plugins, cleaner diagnostics/LSP integration, and modular customization options.
โ To-Do
- Extract custom components from
nvim2k - Build pick-and-choose modular loader
- Add more configuration parameters to individual modules
๐งโ๐ป Behind The Code
๐ Inspiration
homegrown.nvim was inspired by the need to share private configurations, utilities, and helper commands with others without forcing them to adopt an entire pre-configured editor setup.
๐ก Challenges/Learnings
- Refactoring monolithic keymaps and auto-commands to be fully encapsulated within standard plugin module boundaries.
- Decoupling user configurations from shared utilities to keep dependencies minimal.
๐งฐ Tooling
๐ More Info
- co-author.nvim โ Git commit co-authors automation tool
- exercism.nvim โ Exercism.org coding exercises client
- markit.nvim โ Interactive, rich visual Neovim marks manager
- nerdy.nvim โ Search and insert Nerd Font glyphs directly within Neovim
- octohub.nvim โ GitHub repository explorer and manager
- pickme.nvim โ Unified interface wrapper for Telescope, FZF-Lua, and Snacks pickers
- seeker.nvim โ Progressive file and grep selector
- tdo.nvim โ Minimalist note-taking and todo manager
- template.nvim โ Boilerplate starter template for Neovim plugins
- termim.nvim โ Floating and split terminal manager
- utils.nvim โ Shared Lua utilities for Neovim plugins
โญ hit the star button if you found this useful โญ
Source | Blog | Twitter | LinkedIn | More Links | Other Projects