- Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbundle.lua
More file actions
Latest commit
23 lines (19 loc) · 466 Bytes
/
Copy pathbundle.lua
File metadata and controls
23 lines (19 loc) · 466 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
-- bundle: command line tool for bundling files
localcomponent=require("component")
localshell=require("shell")
require("libbundle")
localargs,opts=shell.parse(...)
localargc=#args
if(argc<1or (opts.d==nilandargc<2)) then
print("Usage: bundle [-d] <bundled file> [<input file>, ...]")
return
end
if(opts.d~=nil) then
Unbundle(args[1])
else
localt={}
fori=2,argc,1do
table.insert(t,args[i])
end
Bundle(t,args[1])
end