publish.js 594 B

123456789101112131415161718
  1. const ch = require("child_process");
  2. const packages = ["backend-cli", "service", "events", "pc-components", "utils"];
  3. packages.forEach((name) => {
  4. if (!["backend-cli", "events"].includes(name)) {
  5. console.log(`******** build package: ${name} ************`);
  6. ch.execSync(`pnpm -r --filter=${name} run build `, { stdio: "inherit" });
  7. }
  8. console.log(`======== publish package: ${name} ============`);
  9. try {
  10. ch.execSync(
  11. `pnpm -r --filter=${name} publish --registry http://192.168.20.245:4873/ --no-git-checks`,
  12. { stdio: "inherit" }
  13. );
  14. } catch (err) {}
  15. });