Automatically detects indentation style (tabs vs spaces and indent size) for Neovim buffers.
Guess-indent is a Neovim plugin that automatically detects the indentation style (tabs vs spaces and indent size) used in a file and updates the buffer's settings to match. It solves the problem of manually configuring indentation for each file, ensuring consistent editing experiences across different codebases.
Neovim users who work with multiple projects or codebases that have varying indentation styles and want their editor to adapt automatically.
Developers choose guess-indent for its blazing fast performance written in Lua, seamless automatic detection, and its ability to mimic Sublime Text's indentation guessing feature directly within Neovim.
Automatic indentation style detection for Neovim
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Written in Lua and optimized to run detection in under a millisecond, even for large files, ensuring no perceptible editor slowdown.
Scans the first few hundred lines when opening a buffer to infer indentation style and size, automatically updating editor settings to match the file.
Allows excluding specific filetypes or buffer types, overriding .editorconfig, and customizing tab/space options through a simple setup function.
Replicates the 'Guess Indentation Settings From Buffer' functionality from Sublime Text, offering a familiar experience for users switching editors.
Only analyzes the initial portion of a file (first few hundred lines), which can lead to incorrect settings if indentation varies later in the document.
Uses a straightforward detection method that may be less accurate for files with complex or irregular indentation patterns compared to more advanced alternatives like vim-sleuth.
Built specifically for Neovim and not compatible with standard Vim, limiting its use for users on different editor setups.
guess-indent.nvim is an open-source alternative to the following products: