const { mkdirSync } = require("fs");
const { resolve } = require("path");

const vsce = require("vsce");

const package = require(resolve(__dirname, "..", "package.json"));

try {
    mkdirSync(resolve(__dirname, "..", "vsix"));
} catch (err) {
    if (err.code !== "EEXIST")
        throw err;
}

vsce.createVSIX({
    packagePath: resolve(__dirname, "..", "vsix", `${package.name}-${package.version}-${process.arch}.vsix`)
});

@@ -434,13 +434,93 @@
 vsix%60)%0D%0A
+%7D).catch(function(err) %7B%0D%0A    console.error(err.stack);%0D%0A    process.exit(-1);%0D%0A
 %7D);%0D%0A

Throw error when package failed