Skip to content

v1.4.0 - Auto-Bundling & Multi-File Projects

Choose a tag to compare

@twilson63 twilson63 released this 03 Jul 15:35
· 58 commits to main since this release

🚀 Hype v1.4.0 - Auto-Bundling & Multi-File Projects

🎉 Major New Features

📁 Auto-Bundling in Build Command

The build command now automatically detects and bundles dependencies! No more manual bundling required.

# Just works - auto-bundles multi-file projects
./hype build main.lua -o myapp

🔧 Multi-File Project Support

Create larger projects by splitting code across multiple files:

-- utils.lua
local M = {}
function M.greet(name)
    return "Hello, " .. name .. "\!"
end
return M

-- main.lua  
local utils = require('./utils')
print(utils.greet("World"))

🎯 Smart Module Resolution

  • Relative paths: require('./utils'), require('../helpers')
  • Module names: require('utils') (looks for utils.lua or utils/init.lua)
  • Built-in modules: require('http'), require('kv'), require('tui') (always available)

✨ What's Changed

New Commands

  • Auto-bundling: build command now bundles dependencies automatically
  • Explicit bundling: bundle command for manual bundling (optional)
  • Removed: bundle-build command (now redundant)

Improved Workflow

# Old workflow (still works)
./hype build single-file.lua -o app

# New workflow (just works with multi-file projects)  
./hype build main.lua -o app  # Auto-bundles dependencies

# Optional explicit bundling
./hype bundle main.lua -o bundled.lua

Documentation Updates

  • Updated README with multi-file project examples
  • Added bundling documentation to website
  • New workflow examples and use cases

🔧 Technical Improvements

  • Circular dependency detection
  • Recursive dependency resolution
  • Preserves module scope and returns
  • Zero breaking changes to existing workflows

📦 Download

Choose your platform:

  • Linux: luax-v1.4.0-linux-amd64.tar.gz (x86_64) or luax-v1.4.0-linux-arm64.tar.gz (ARM64)
  • macOS: luax-v1.4.0-darwin-amd64.tar.gz (Intel) or luax-v1.4.0-darwin-arm64.tar.gz (Apple Silicon)
  • Windows: luax-v1.4.0-windows-amd64.zip

🚀 Quick Install

# Cross-platform installer
curl -sSL https://raw.githubusercontent.com/twilson63/hype/main/install.sh | bash

Full Changelog: v1.3.1...v1.4.0