1
0
mirror of https://github.com/louislam/uptime-kuma.git synced 2025-10-30 23:58:13 +02:00

Fix: release script do not update lock file correctly (#6257)

This commit is contained in:
Paulus Lucas
2025-10-26 10:10:16 +01:00
committed by GitHub
parent 83c3cfc8c0
commit b7bb961eac

View File

@@ -27,7 +27,18 @@ if (! exists) {
// Also update package-lock.json
const npm = /^win/.test(process.platform) ? "npm.cmd" : "npm";
childProcess.spawnSync(npm, [ "install" ]);
const resultVersion = childProcess.spawnSync(npm, [ "--no-git-tag-version", "version", newVersion ], { shell: true });
if (resultVersion.error) {
console.error(resultVersion.error);
console.error("error npm version!");
process.exit(1);
}
const resultInstall = childProcess.spawnSync(npm, [ "install" ], { shell: true });
if (resultInstall.error) {
console.error(resultInstall.error);
console.error("error update package-lock!");
process.exit(1);
}
commit(newVersion);
} else {