1 unstable release
new 0.1.0 | Feb 18, 2025 |
---|
#553 in Development tools
Used in lux-cli
585KB
15K
SLoC
A [WIP] Library & Client implementation of luarocks
[!WARNING]
lux is a work in progress and does not have a stable release yet.
Lux serves as an application for:
- Installing and managing rocks
- Creating Lua projects with dependencies, build scripts and desired Lua versions
- Creating and publishing your own rocks
- Embedding rock manipulation logic into your own application
[!NOTE]
This aims to be a full rewrite of
luarocks
, with many flags altered to be more ergonomic. This is not a drop-in replacement forluarocks
commands you may have in scripts.
📚 Usage
lx <command> <options>
To view available options and their descriptions, run lx --help
.
Comparison with luarocks v3.11.1
As this project is still a work in progress, some luarocks features have not been (fully) implemented yet. On the other hand, lux has some features that are not present in luarocks.
The following table provides a brief (incomplete) comparison:
lux | luarocks v3.11.1 | |
---|---|---|
builtin build spec |
✅ | ✅ |
make build spec |
✅ | ✅ |
cmake build spec |
✅ | ✅ |
command build spec |
✅ | ✅ |
custom build backends | ✅[^1] | ✅ |
rust-mlua build spec |
✅ (builtin) | ✅ (external build backend) |
RockSpecs with CVS/Mercurial/SVN/SSCM sources | ❌ (YAGNI[^2]) | ✅ |
install pre-built binary rocks | ✅ | ✅ |
parallel builds/installs | ✅ | ❌ |
install multiple packages with a single command | ✅ | ❌ |
install packages using version constraints | ✅ | ❌ |
proper lockfile support with integrity checks | ✅ | ❌ (basic, dependency versions only) |
auto-detect external dependencies and Lua headers with pkg-config |
✅ | ❌ |
automatic lua detection/installation | ✅ | ❌ |
resolve multiple versions of the same dependency at runtime | ❌ (planned) | ✅ |
run tests with busted | ✅ | ✅ |
code formatting with stylua | ✅ | ❌ |
linting with luacheck | ✅ | ❌ |
static type checking | ❌ (planned) | ❌ |
pack and upload pre-built binary rocks | ✅ | ✅ |
add/remove dependencies | ✅ | ❌ |
luarocks.org manifest namespaces | ✅ | ✅ |
luarocks.org dev packages | ✅ | ✅ |
[^1]: Supported via a compatibility layer that uses luarocks as a backend. [^2]: You Aren't Gonna Need It.
📖 License
Lux is licensed under MIT.
💚 Contributing
Contributions are more than welcome! See CONTRIBUTING.md for a guide.
Dependencies
~42–58MB
~1M SLoC