aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorV <vendicated@riseup.net>2023-09-21 18:56:58 +0200
committerV <vendicated@riseup.net>2023-09-21 18:56:58 +0200
commit97b6699afefe373d510dda5589a0754a4b380153 (patch)
tree112c8dd963aa4ed64702c9444738fbcca9d4674a /scripts
parent7e91edc7577ba65fab08bc45c07cbd6f1756bd6f (diff)
downloadVencord-97b6699afefe373d510dda5589a0754a4b380153.tar.gz
Vencord-97b6699afefe373d510dda5589a0754a4b380153.tar.bz2
Vencord-97b6699afefe373d510dda5589a0754a4b380153.zip
Fuck you Mozilla
Diffstat (limited to 'scripts')
-rw-r--r--scripts/build/buildWeb.mjs6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/build/buildWeb.mjs b/scripts/build/buildWeb.mjs
index 02e4da0..e4eeb53 100644
--- a/scripts/build/buildWeb.mjs
+++ b/scripts/build/buildWeb.mjs
@@ -145,11 +145,11 @@ async function loadDir(dir, basePath = "") {
/**
* @type {(target: string, files: string[]) => Promise<void>}
*/
-async function buildExtension(target, files) {
+async function buildExtension(target, files, noMonaco = false) {
const entries = {
"dist/Vencord.js": await readFile("dist/extension.js"),
"dist/Vencord.css": await readFile("dist/extension.css"),
- ...await loadDir("dist/monaco"),
+ ...(noMonaco ? {} : await loadDir("dist/monaco")),
...Object.fromEntries(await Promise.all(RnNoiseFiles.map(async file =>
[`third-party/rnnoise/${file.replace(/^dist\//, "")}`, await readFile(`node_modules/@sapphi-red/web-noise-suppressor/${file}`)]
))),
@@ -195,7 +195,7 @@ const appendCssRuntime = readFile("dist/Vencord.user.css", "utf-8").then(content
await Promise.all([
appendCssRuntime,
buildExtension("chromium-unpacked", ["modifyResponseHeaders.json", "content.js", "manifest.json", "icon.png"]),
- buildExtension("firefox-unpacked", ["background.js", "content.js", "manifestv2.json", "icon.png"]),
+ buildExtension("firefox-unpacked", ["content.js", "manifestv2.json", "icon.png"], true),
]);
Zip.sync.zip("dist/chromium-unpacked").compress().save("dist/extension.zip");