Skip to content

naranyala/awesome-vimscript-and-lua

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 

Repository files navigation

Awesome Vimscript & Lua for Vim/Neovim

A curated list of Vimscript (VimL) and Lua resources, tools, and utilities for Vim and Neovim plugin development and configuration.

Vimscript is the built-in scripting language of Vim. Lua is an embedded scripting language in Neovim, introduced in version 0.5 with the vim.api interface. This list focuses on the languages themselves — learning resources, development tools, libraries, and plugins written in these languages.


Contents


Vimscript Language Resources

Official references and tutorials for learning Vimscript (VimL):

Vim9 Script

Vim 9's revised scripting language with type declarations and compiled execution:

  • Vim9 Script Documentation (:help vim9) — Official Vim reference for Vim9 syntax and semantics, including typed variables, compile-time checks, and class/object syntax.
  • Learn Vim9 Script in Y Minutes — Single-page overview of Vim9 syntax with comparisons to Vim legacy script.
  • Vim9 Script Style Guide — Community style guide for Vim9 script covering naming conventions, formatting, and plugin organization.

Lua Language Resources

Resources for learning Lua as used in Neovim (Neovim uses LuaJIT, based on Lua 5.1):

Lua for Neovim

Applying Lua specifically within Neovim:

Official Documentation


Plugin Managers

Tools for installing, updating, and managing Vim/Neovim plugins:

Cross-Compatibility (Vim & Neovim)

  • vim-plug — Plugin manager with parallel installation, on-demand loading, and rollback support. Configured in Vimscript.
  • Vundle — Vim plugin manager. Uses Plugin declarations in .vimrc.
  • Pathogen — Prepends directories to 'runtimepath'. Requires manual cloning of plugin repositories.
  • dein.vim — Plugin manager with lazy loading support, TOML-based configuration. Successor to NeoBundle.
  • Vim 8+ Native Packages — Vim 8.0+ built-in package management via pack/ directory.

Neovim-Only (Lua Configuration)

  • lazy.nvim — Plugin manager with dependency resolution, lazy loading, and a UI for managing plugins. Configured in Lua.
  • packer.nvim — Plugin manager using Neovim's native package system with Lua DSL configuration. Supports compilation of plugin specs.
  • mini.deps — Plugin management module from the mini.nvim collection.

Neovim Distributions & Starter Configs

Pre-configured Neovim setups demonstrating Lua configuration patterns:

  • LazyVim — Neovim configuration built on lazy.nvim. Provides a plugin extension system.
  • Kickstart.nvim — Single-file Neovim configuration (~500 lines) with commented examples of plugin manager, LSP, Treesitter, completion, and telescope.
  • NvChad — Neovim configuration with custom UI, plugin management via lazy.nvim, and theme support.
  • LunarVim — Neovim distribution with its own CLI tool (lvim), built-in plugin management, and IDE-like defaults.
  • AstroNvim — Neovim configuration focused on providing a complete IDE experience with LSP, DAP, and Treesitter pre-configured.
  • Mini.Starter — Configurable start screen, can serve as a minimal starting point.

Plugin Development Tools

Tools for writing, debugging, and maintaining Vim/Neovim plugins:

Lua Plugin Development

  • neodev.nvim — Type checking, signature help, and autocompletion for the Neovim Lua API during plugin development.
  • lazydev.nvim — Follow-up to neodev.nvim. Lua type checking and autocompletion for Neovim development.
  • nvim-luaref — Displays built-in Lua function reference documentation within Neovim.
  • nlua.nvim — Lua development tools for Neovim with debugging capabilities and REPL integration.
  • nvim-plugin-dev-handbook — Guide for Neovim plugin development best practices.

Vimscript Plugin Development

  • scriptease.vim — Commands for Vimscript development: :Scriptnames, :Messages, :Verbose, :Time. Includes profiling.
  • vim-test — Run tests for Vimscript/Neovim plugins from the editor.
  • vader.vim — BDD-style testing framework for Vimscript plugins.
  • vim-themis — Vim script testing framework with various assertion styles.

Testing Frameworks

Frameworks for writing and running tests for Vim/Neovim plugins:

  • plenary.test_harness — Neovim Lua test runner. Provides describe() / it() blocks, async test support, and temporary directory management.
  • busted — General-purpose Lua testing framework. Compatible with Neovim plugin testing.
  • luassert — Assertion library for Lua. Commonly paired with busted.
  • vader.vim — BDD-style testing framework for Vimscript plugins.
  • vim-themis — Vim script testing framework with various assertion styles.
  • vim-vspec — Vimscript testing framework.

Static Analysis & Formatting

Tools for analyzing and formatting Vimscript and Lua code:

Lua

  • stylua — Lua code formatter. Written in Rust. Configurable indent width, column width, and quote style.
  • luacheck — Static analyzer for Lua code. Detects unused variables, globals, unreachable code, and style issues.
  • selene — Lua linter written in Rust. Provides type checking and configurable lint rules.
  • lua-language-server — Language Server Protocol implementation for Lua. Provides diagnostics, autocompletion, and go-to-definition.

Vimscript

  • vimlint — Lint checker for Vim script. Detects unused variables, undefined functions, and style issues.
  • vimlparser — Vim script parser library. Used by vimlint and other Vimscript analysis tools.

Style Guides


Lua Libraries & Utility Modules

Lua modules providing reusable functionality for Neovim plugin development:

  • plenary.nvim — Utility library providing: async job control (plenary.job), path/file manipulation (plenary.path), testing framework (plenary.test_harness), module reloading (plenary.reload), JSON/XML parsing, and data structures.
  • nvim-nio — Async I/O library for Neovim. Provides an async/await API for non-blocking operations.
  • dressing.nvim — Overrides vim.ui.select and vim.ui.input with alternative UI implementations.
  • persistence.nvim — Session management with auto-save and restore.
  • snacks.nvim — Collection of QoL features: dashboard, picker, notifier, terminal, indentation, scope, words.
  • mini.nvim — Library of 40+ independent Lua modules covering pairs, surround, completion, align, comment, and more.
  • neoconf.nvim — Manage global and project-local Neovim settings with JSON/JSONC files.
  • nabla.nvim — Take notes with LaTeX and code support directly in Neovim.
  • sqlite.lua — SQLite binding for Neovim. Provides a Lua interface for SQLite databases.

Vimscript Libraries & Utility Modules

Vimscript libraries providing reusable functionality:

  • vital.vim — Module library for Vim plugins. Provides modules for data structures (Data.List, Data.Set, Data.OrderedSet), strings (String, String.Builders), process management (Process), mapping utilities, option parsing, and prelude functions.
  • ingo-library — Autoload library of common Vimscript functions used across multiple plugins. Includes functions for text manipulation, pattern matching, window/buffer management, and plugin interaction.
  • vimproc.vim — External command execution library for Vim. Provides functions for running commands in the background.
  • plib.vim — Python standard library-style functions applied to Vim objects (lists, strings, tables).

Plugins Written in Lua

Plugins implemented primarily in Lua, demonstrating Lua plugin development patterns:

Editor UI

  • lualine.nvim — Status line plugin. Configurable sections (mode, filename, git branch, diagnostics). Supports themes and custom components.
  • noice.nvim — Replaces Vim's default UI for messages, command line, and popup menu. Provides configurable message history and cmdline UI.
  • nvim-notify — Notification manager. Supports grouping, icons, timeout, and animation stages. Overrides vim.notify.
  • nvim-tree.lua — File explorer. Displays directory tree with file icons and git status indicators.
  • oil.nvim — File explorer that renders the file system as an editable buffer. File operations are performed by editing buffer text.
  • neo-tree.nvim — File tree explorer. Supports file system, buffers, and git sources.
  • alpha-nvim — Dashboard/start screen. Configurable with buttons, headers, file lists, and session management.
  • dashboard-nvim — Dashboard plugin. Supports themes, recent files, and custom sections.
  • indent-blankline.nvim — Displays indentation guides and scope lines. Supports Treesitter-aware scope detection.
  • which-key.nvim — Displays available keybindings in a popup panel as the user types a prefix.
  • hydra.nvim — Creates keybinding modes with multiple heads.
  • nvim-ufo — Code folding. Uses LSP and Treesitter for fold detection.
  • nvim-scrollbar — Scrollbar. Displays diagnostic, search, and git signs.
  • no-neck-pain.nvim — Centers the main buffer and dims surrounding windows.

File Navigation

Code Editing

  • nvim-cmp — Autocompletion engine. Supports multiple sources via separate source plugins.
  • LuaSnip — Snippet engine. Supports VS Code snippet format, nested snippets, conditionals, and dynamic snippets.
  • coq_nvim — Autocompletion engine using SQLite for candidate storage.
  • nvim-surround — Add, delete, and change surround characters (parentheses, quotes, HTML tags).
  • Comment.nvim — Line and block commenting. Uses Treesitter for language-aware comment strings.
  • nvim-autopairs — Auto-pairs for brackets, quotes, and tags. Configurable rules and conditional pairing.
  • leap.nvim — Cursor motion. Assigns labels to visible targets for jumping across lines and windows.
  • flash.nvim — Navigation. Provides labeled jumping, Treesitter-aware motions, and search integration.
  • Hop.nvim — Cursor motion. Displays hints at visible positions for jumping.
  • flit.nvim — Extends native f/F/t/T motions with leap.nvim-based multi-line jumping.
  • multicursors.nvim — Multiple cursors. Integrates with hop.nvim for cursor placement.
  • yanky.nvim — Yank and put. Maintains a yank ring, supports clipboard, and provides a picker to browse yank history.
  • todo-comments.nvim — Highlights and searches for TODO, FIXME, HACK, NOTE, and other comment markers. Provides Telescope integration.
  • smartcolumn.nvim — Displays a colorcolumn at a configurable column width.

LSP & Diagnostics

  • nvim-lspconfig — Default configurations for language servers used with Neovim's built-in LSP client.
  • mason.nvim — Package manager for LSP servers, DAP servers, linters, and formatters.
  • mason-lspconfig.nvim — Integration between mason.nvim and nvim-lspconfig.
  • mason-tool-installer.nvim — Automatically installs mason.nvim packages on Neovim startup.
  • lsp-zero.nvim — Pre-configured LSP setup bundling nvim-lspconfig, nvim-cmp, and related plugins.
  • conform.nvim — Code formatter. Integrates with LSP formatters and CLI formatters.
  • null-ls.nvim — Injects diagnostics, code actions, and formatting from CLI tools into Neovim's LSP system.
  • none-ls.nvim — Fork of null-ls.nvim. Maintains compatibility with the null-ls API.
  • lspsaga.nvim — LSP UI: hover, code actions, rename, diagnostics, and call hierarchy in floating windows.
  • lsp-lines — Displays LSP diagnostics using virt_text on the line below the error.
  • trouble.nvim — Displays diagnostics, references, LSP symbols, quickfix, and location lists in a formatted list.
  • fidget.nvim — Displays LSP server progress indicators in the status line.
  • lsp_signature.nvim — Displays function signature hints while typing.
  • refactoring.nvim — Refactoring operations: extract to function/variable, inline variable, toggle anonymous function.
  • nvim-dap — Debug Adapter Protocol client. Provides breakpoints, step execution, variable inspection, and watch expressions.
  • nvim-dap-ui — UI for nvim-dap. Displays variables, breakpoints, watches, and a REPL.
  • nvim-dap-virtual-text — Displays variable values as virtual text inline during debug sessions.
  • one-small-step-for-vimkind — DAP adapter for Lua code running inside Neovim.

Git Integration

  • gitsigns.nvim — Git integration. Displays diff signs, provides stage/unstage hunks, blame preview, and hunk navigation.
  • neogit — Git interface. Provides interactive staging, committing, branching, rebasing, and log viewing.
  • diffview.nvim — Tab-based diff viewer. Supports file history, merge conflict resolution, and range diffs.
  • octo.nvim — GitHub integration. Browse, review, and manage issues and pull requests.
  • lazygit.nvim — Opens lazygit (terminal Git UI) inside Neovim.
  • git.nvim — Git plugin providing blame, browse, commit, and diff functionality.

General Utilities

  • toggleterm.nvim — Manages persistent terminal buffers. Supports floating windows, split terminals, and lazy loading.
  • overseer.nvim — Task runner and job management. Provides a task template system and UI for running build commands.
  • project.nvim — Project management. Auto-detects project directories, provides Telescope integration.
  • harpoon — File bookmarking. Marks files for access with numbered shortcuts.
  • harpoon2 — Updated version of harpoon with revised API and UI.
  • grapple.nvim — File tagging and navigation. Supports scopes, git integration, and persistent tags.
  • marks.nvim — Mark management. Displays marks in the sign column, provides navigation and deletion commands.
  • clipboard-image.nvim — Pastes images from clipboard into buffers. Supports Markdown, Org, and AsciiDoc.
  • registers.nvim — Displays register contents in a popup window.
  • aerial.nvim — Displays a symbol outline (functions, classes, variables) in a sidebar. Uses LSP or Treesitter.
  • nvim-bqf — Modifies Vim's built-in quickfix window with preview, filtering, and fzf integration.
  • symbols-outline.nvim — Tree view of document symbols using LSP.

Plugins Written in Vimscript

Plugins implemented primarily in Vimscript, demonstrating Vimscript plugin development patterns:

File Navigation

  • NERDTree — File system tree browser. Supports file operations (open, delete, rename, copy).
  • vim-dirvish — File browser that replaces Vim's built-in netrw. Displays directory listing in a normal buffer.
  • vim-vinegar — Extends Vim's netrw file browser with additional navigation and file operation features.
  • fern.vim — File explorer. Supports multiple sources and custom actions.
  • vim-startify — Start screen. Displays recent files, sessions, and bookmarks.

Code Editing

General Utilities

  • vim-fugitive — Git wrapper. Provides commands for :Git, :Gread, :Gwrite, :Gdiff, :Gblame, and more.
  • vim-rhubarb — Fugitive extension for GitHub. Enables :GBrowse to open files on GitHub.
  • vim-gitgutter — Shows Git diff signs in the sign column.
  • vim-signify — Shows diff signs from Git, SVN, or Mercurial in the sign column.
  • vim-sleuth — Auto-detects shiftwidth and tabstop from file content.
  • vim-speeddating — Extends Ctrl-A/Ctrl-X to increment/decrement dates, times, fractions, and more.
  • vim-abolish — Substitution and abbreviation. Handles case variations (snake_case, camelCase, TitleCase).
  • vim-unimpaired — Complementary key mappings for built-in Vim commands.
  • vim-repeat — Enables . (dot command) to repeat custom mappings from other plugins.
  • vim-move — Move lines up/down with Alt+j/Alt+k.
  • vim-bookmarks — Bookmark management.
  • vim-signature — Toggle, navigate, and display marks in the sign column.
  • vim-yoink — Yank ring and clipboard manager.
  • vim-obsession — Session management. Wraps Vim's :mksession with modified defaults.
  • ALE (Asynchronous Lint Engine) — Linting and fixing engine. Runs linters asynchronously. Supports 100+ tools across 50+ filetypes.

Cross-Compatible Plugins (Vim & Neovim)

Plugins that work in both Vim and Neovim, demonstrating cross-compatible development patterns:

Editor UI

  • vim-airline — Status/tab line plugin. Provides extensions for branch, diagnostics, file encoding, and more.
  • lightline.vim — Status line plugin. Configurable left/right components.
  • indentLine — Displays thin vertical lines at each indentation level.
  • vim-which-key — Vimscript port of which-key functionality.

Code Editing

General Utilities

  • vim-tmux-navigator — Navigation between Vim splits and tmux panes.
  • vimux — Runs Vim commands in a tmux pane.
  • neoterm — Manages terminal REPL sessions integrated with Vim/Neovim.
  • vim-slime — Sends text from Vim to a tmux pane (or other terminal multiplexer).
  • vim-clipboard — Clipboard integration.
  • emmet-vim — HTML/CSS abbreviation expansion.
  • ctrlp.vim — Full-path fuzzy file, buffer, and tag finder.
  • fzf.vim — Vimscript wrapper around fzf. Provides commands (:Files, :Buffers, :Lines, :Tags).
  • denite.nvim — Unified interface for gathering and displaying information from any source. Written in Python3 and Vimscript.
  • coc.nvim — IntelliSense engine. Runs as a Node.js process. Provides LSP, snippets, completion, diagnostics, and code actions.
  • vim-dadbod — Database interface. Connects to databases via URL strings.
  • vim-dadbod-ui — UI for vim-dadbod. Provides a query buffer and results display.
  • vim-qf — Modifies Vim's quickfix window with navigation and usability features.
  • vim-adequate-yank — Yank/put management.
  • jedi-vim — Python autocompletion using the Jedi library.
  • vim-go — Go development plugin. Provides syntax, linting, testing, and code generation.
  • vim-ruby — Ruby syntax highlighting and indentation.
  • vim-elixir — Elixir syntax highlighting.
  • typescript-vim — TypeScript syntax highlighting.
  • vim-jsx — JSX syntax highlighting.
  • vim-toml — TOML syntax support.
  • rust.vim — Rust syntax highlighting and configuration.

Treesitter & Syntax Highlighting

Treesitter-related plugins for Neovim (nvim-treesitter provides the core integration):

  • nvim-treesitter — Treesitter integration for Neovim. Provides syntax highlighting, incremental selection, indentation, and text objects.
  • nvim-treesitter-textobjects — Treesitter-based text objects for functions, classes, parameters, loops, conditionals.
  • nvim-treesitter-context — Displays code context (function/class/if block) at the top of the window as the cursor scrolls.
  • playground.nvim — Treesitter syntax tree viewer. Displays the parsed AST with query highlighting.
  • ts-comments.nvim — Treesitter-aware comment string detection.
  • nvim-treesitter-refactor — Treesitter-based refactoring module. Provides rename and extract functionality.
  • rainbow-delimiters.nvim — Rainbow-colored bracket/parenthesis highlighting using Treesitter parsing.
  • vim-polyglot — Collection of language packs for Vim/Neovim. Bundles syntax files for 100+ languages. Written in Vimscript.

Note-Taking & Markup

Plugins demonstrating text markup integration with Vimscript/Lua patterns:

  • vimwiki — Personal wiki. Supports Markdown, HTML, and custom syntax. Written in Vimscript.
  • vim-markdown — Markdown syntax highlighting and folding. Written in Vimscript.
  • markdown-preview.nvim — Markdown preview plugin. Opens rendered Markdown in a web browser with live reload.
  • render-markdown.nvim — Renders Markdown with Treesitter: checkboxes, code blocks, headings, tables, and callouts.
  • obsidian.nvim — Integration for Obsidian.md vaults. Supports note linking, tags, templates, daily notes, and YAML frontmatter.
  • neorg — Note-taking and task management. Uses a custom file format (.norg) parsed by Treesitter.
  • orgmode.nvim — Emacs Org-mode implementation. Supports agendas, TODO tracking, clocking, and Treesitter parsing.

Community & Discovery


Related Awesome Lists

  • awesome-neovim — List of Neovim plugins, tools, and resources.
  • awesome-vim — Vim plugin list organized by category.
  • vim-plugin-list — JSON-formatted list of Vim/Neovim plugins.
  • awesome-lua — Lua ecosystem resources, including a Neovim section.
  • neovim-plugin-list — GitHub topic page for Lua-based Neovim plugins.
  • kickstart.nvim — Single-file Neovim configuration with documentation. Suitable as a learning resource.

Contributing

Contributions are welcome. Please follow these guidelines:

  • Add resources related to Vimscript or Lua for Vim/Neovim.
  • Include a factual description of what the resource does.
  • Avoid subjective claims.
  • Prefer linking to the primary source repository.
  • Note whether a plugin is Vim-compatible, Neovim-only, or Lua-only.

License

CC0

To the extent possible under law, the authors have waived all copyright and related or neighboring rights to this work.

About

A curated list of Vimscript (VimL) and Lua resources, tools, and utilities for Vim and Neovim plugin development and configuration.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors