fix
This commit is contained in:
parent
b8fdf0911a
commit
5ca9325e16
@ -5,7 +5,7 @@
|
||||
#
|
||||
# Script assumes we're in basedir of the repository and that extension has been built and zipped to /dist-zip
|
||||
# using the crx name we want (same name as zip, except different extension)
|
||||
#
|
||||
#
|
||||
# also this doesn't check for errors ever so
|
||||
#
|
||||
|
||||
@ -42,4 +42,4 @@ sig_len_hex=$(byte_swap $(printf '%08x\n' $(ls -l "$sig" | awk '{print $5}')))
|
||||
echo "Wrote $crx"
|
||||
|
||||
echo "exiting dist-zip"
|
||||
cd ..
|
||||
cd ..
|
||||
|
@ -24,7 +24,7 @@ const buildZip = (src, dist, zipFilename) => {
|
||||
|
||||
const archive = archiver('zip', { zlib: { level: 9 }});
|
||||
const stream = fs.createWriteStream(path.join(dist, zipFilename));
|
||||
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
archive
|
||||
.directory(src, false)
|
||||
@ -46,14 +46,14 @@ const main = () => {
|
||||
browserPostfix = browser;
|
||||
}
|
||||
const destDir = path.join(__dirname, `../dist-${browserPostfix}`);
|
||||
const zipDir = path.join(__dirname, '../dist-zip');
|
||||
const zipDir = path.join(__dirname, '../dist-zip');
|
||||
const {name, version} = extractExtensionData(browserPostfix);
|
||||
|
||||
// collapse spaces and dashes into single dash
|
||||
const baseFilename = `${name.replace(/[ -]+/g, '-')}-${version}`;
|
||||
|
||||
let realZipDir;
|
||||
|
||||
|
||||
if (!!testingOrNightly) {
|
||||
realZipDir = path.join(zipDir, version);
|
||||
} else {
|
||||
@ -61,7 +61,7 @@ const main = () => {
|
||||
}
|
||||
|
||||
const zipFilename = `${baseFilename}-${browser}.zip`;
|
||||
|
||||
|
||||
try {
|
||||
makeDirIfNotExists(realZipDir, {recursive: true});
|
||||
} catch (e) {
|
||||
@ -70,7 +70,7 @@ const main = () => {
|
||||
}
|
||||
buildZip(destDir, realZipDir, zipFilename)
|
||||
.then(() => console.info('OK'))
|
||||
.catch(console.err);
|
||||
.catch(console.err);
|
||||
};
|
||||
|
||||
main();
|
||||
|
Loading…
Reference in New Issue
Block a user