2021-10-10 11:02:25 +02:00
|
|
|
const path = require("path");
|
|
|
|
const fs = require("fs");
|
|
|
|
const parts = ["api", "util", "cdn", "gateway"];
|
|
|
|
|
|
|
|
const bundle = require("../package.json");
|
|
|
|
|
|
|
|
for (const part of parts) {
|
2021-10-20 02:11:12 +02:00
|
|
|
const { devDependencies, dependencies } = require(path.join(
|
|
|
|
"..",
|
|
|
|
"..",
|
|
|
|
part,
|
|
|
|
"package.json"
|
|
|
|
));
|
2021-10-10 11:02:25 +02:00
|
|
|
bundle.devDependencies = { ...bundle.devDependencies, ...devDependencies };
|
|
|
|
bundle.dependencies = { ...bundle.dependencies, ...dependencies };
|
|
|
|
delete bundle.dependencies["@fosscord/util"];
|
|
|
|
}
|
|
|
|
|
2021-10-20 02:11:12 +02:00
|
|
|
fs.writeFileSync(
|
|
|
|
path.join(__dirname, "..", "package.json"),
|
|
|
|
JSON.stringify(bundle, null, "\t"),
|
|
|
|
{ encoding: "utf8" }
|
|
|
|
);
|