1
0
mirror of https://github.com/louislam/uptime-kuma.git synced 2024-11-24 08:32:23 +02:00
uptime-kuma/extra/checkout-pr.js

12 lines
363 B
JavaScript
Raw Normal View History

2022-09-03 12:37:31 +02:00
const childProcess = require("child_process");
if (!process.env.UPTIME_KUMA_PRUPTIME_KUMA_PR) {
console.error("Please set a pull request number to the environment variable 'UPTIME_KUMA_PRUPTIME_KUMA_PR'");
process.exit(1);
}
console.log("Checkout pr");
// Checkout the pr
childProcess.spawnSync("gh", [ "pr", "checkout", process.env.UPTIME_KUMA_PR ]);