22 lines
541 B
JavaScript
Executable File
22 lines
541 B
JavaScript
Executable File
#!/usr/bin/env node
|
|
const { execFileSync } = require('child_process');
|
|
|
|
const bundlejs = 'src/app/bundle.js'
|
|
const bundlets = 'src/app/bundle.d.ts'
|
|
|
|
var pbjs_args = [
|
|
'-t', 'static-module', '-w', 'commonjs', '-o', bundlejs
|
|
].concat(process.argv.slice(2));
|
|
|
|
console.log("Running pbjs " + pbjs_args.join(" "));
|
|
var out = execFileSync('pbjs', pbjs_args);
|
|
console.log("" + out);
|
|
|
|
var pbts_args = [
|
|
'-o', bundlets, bundlejs
|
|
];
|
|
|
|
console.log("Running pbts " + pbts_args.join(" "));
|
|
out = execFileSync('pbts', pbts_args);
|
|
console.log("" + out);
|