About Lux
Lux — A luxurious package manager for Lua. It was shared on Show HN in 2025 and received 268 upvotes on Hacker News. Announcing Lux, a new package manager for Lua that treats Neovim and Nix as first-class citizens and is compatible with LuaRocks. For a bit over a year, we have been cooking up Lux , a new package manager for creating, maintaining and publishing Lua code. Today, we feel the project has hit a state of “very usable for everyday tasks” 1 . Forget about users complaining they have the wrong Lua headers installed on their system. All you need to do is specify compatible lua versions. A fully embeddable lux-lib crate, which can even be built to expose a Lua API. Source + rockspec hashes that can be used to make Lux easy to integrate with Nix . Native support for running tests with busted . Including the ability to use Neovim as a Lua interpreter. Need to install a package that uses a custom luarocks build backend? Motivation Lua While extensive, Luarocks carries with it around 20 years of baggage, which makes it difficult to make suitable for modern Lua development, while retaining backward compatibility. Enforced SemVer: Luarocks allows for arbitrary versions after the patch version. For example, 1.0.1.0.0.0.2 is considered valid by Luarocks, but it has no useful meaning. Because Luarocks is written in Lua, installing a large number of packages and synchronising plugins with rocks.nvim has been painfully slow. Using Lux is non-destructive and doesn’t interfere with the current way of distributing Neovim plugins (which is via git). In fact, Lux has a --nvim flag, which tells it to install packages into a tree structure that is compatible with Neovim’s :h packages . Nix If a Neovim plugin exists as a Luarocks package, nixpkgs will use it as the source of truth. However, Luarocks has very basic lockfile support, which does not include source hashes. While Luarocks (as does Lux) supports conflicting dependencies via its luarocks.loader , nixpkgs cannot reasonably add multiple versions of the same dependency to its package set.