Skip to content

yatyricky/lua-bundler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Usage

Bundle Lua files into one:

lua-bundler "./example/src/Main.lua" "./example/dist/bundle.lua"

If target file name is war3map.lua, inject bundled source to it:

lua-bundler "./example/src/Main.lua" "./example/dist/war3map.lua"

Add -p, --production to minify bundled lua

lua-bundler "./example/src/Main.lua" "./example/dist/bundle.lua" -p
lua-bundler "./example/src/Main.lua" "./example/dist/war3map.lua" -p

Add -e, --exclude to exclude certain files and directories

lua-bundler "./example/src/Main.lua" "./example/dist/bundle.lua" -e "example/src/Reporter.lua"
lua-bundler "./example/src/Main.lua" "./example/dist/bundle.lua" -e "example/src/Reporter.lua;example\src\Dir"

Require flavours

local Module = require("Modules.Module") -- recommended
require("Modules/Module")
require "Modules.Module"

Build with pkg

e.g. pkg . -t node16-win-x64