- Replaced `@luca/esbuild-deno-loader` with a new `build_deps.ts` file to manage build dependencies. - Breaking change to plug-compile: --importmap no longer supported, use -c instead to pass in a deno.json (which can include a "import" map).
33 lines
1018 B
TypeScript
Executable File
33 lines
1018 B
TypeScript
Executable File
import.meta.main = false;
|
|
import { Command } from "@cliffy/command";
|
|
|
|
import { version } from "../version.ts";
|
|
|
|
import { plugCompileCommand } from "../client/plugos/plug_compile.ts";
|
|
|
|
await new Command()
|
|
.name("plug-compile")
|
|
.description("Bundle (compile) one or more plug manifests")
|
|
.version(version)
|
|
.helpOption(false)
|
|
.usage("<options> <manifest paths> | <command> (see below)")
|
|
.arguments("<...name.plug.yaml:string>")
|
|
.option("--debug", "Do not minifiy code", { default: false })
|
|
.option("--info", "Print out size info per function", {
|
|
default: false,
|
|
})
|
|
.option("--watch, -w [type:boolean]", "Watch for changes and rebuild", {
|
|
default: false,
|
|
})
|
|
.option(
|
|
"--dist <path:string>",
|
|
"Folder to put the resulting .plug.json file into",
|
|
{ default: "." },
|
|
)
|
|
.option("-c, --config <path:string>", "Path to deno.json file to use")
|
|
.option("--runtimeUrl <url:string>", "URL to worker_runtime.ts to use")
|
|
.action(plugCompileCommand)
|
|
.parse(Deno.args);
|
|
|
|
Deno.exit(0);
|