in wix/light.js [36:64]
flush(callback) {
const exeLight = path.join(__dirname, "./wix/light.exe");
const argSpdb = options.spdb ? "-spdb" : "";
const outDir = tmp.dirSync({ dir: options.intermediateDir, unsafeCleanup: true }).name;
const argOut = path.join(outDir, options.outFileName);
const argWxsObjs = wxsObjs.map((fileName) => `"${fileName}"`).join(" ");
const cmdLight = `"${exeLight}" -b ${packDir} ${argSpdb} -out ${argOut} ${argWxsObjs}`;
console.info("MSI", "Executing", cmdLight);
exec(cmdLight, { encoding: "utf8" },
(err, stdout, stderr) => {
console.info(stdout);
if (stderr) {
console.error(stderr);
}
if (!err) {
fs.readdirSync(outDir, "utf8")
.forEach((fileName) => {
const filePath = path.join(outDir, fileName);
this.push(vinyl(filePath, outDir));
});
}
callback(err);
});
},