UNPKG

sdin

Version:

JavaScript package builder.

3 lines 1.08 kB
#!/usr/bin/env node import"../tools/entry";import{resolve as e}from"path";import{Command as a}from"commander";import{getRootPath as t}from"../utils/path";import{magenta as o,green as n}from"../utils/print";import{readPackageInfo as r}from"../utils/npm";let c=new a,i=r(t(),!0),m="".concat(o(i.name)," ").concat(n(i.version)),s="\nPackage:\n name: ".concat(o(i.name),"\n version: ").concat(n(i.version),"\n license: ").concat(i.license,"\n author: ").concat(i.author,"\n description: ").concat(i.description,"\n");c.command("create","Create project.",{executableFile:e(__dirname,"./create.js")}).command("start","Start project.",{executableFile:e(__dirname,"./start.js")}).command("build","Build project.",{executableFile:e(__dirname,"./build.js")}).command("test","Test project.",{executableFile:e(__dirname,"./test.js")}).command("play","Play project.",{executableFile:e(__dirname,"./play.js")}).name(Object.keys(i.bin)[0]).version(m,"-v, --version").on("--help",()=>console.log(s)).action(()=>{}).parse(process.argv); //# sourceMappingURL=index.js.map