This commit is contained in:
Dax Raad
2026-01-30 10:11:05 -05:00
parent ad5d495b2c
commit 5e823fd208

View File

@@ -49,24 +49,8 @@ async function main() {
continue
}
// Try to rebase onto current beta branch
console.log(` Attempting to rebase PR #${pr.number}...`)
const rebase = await $`git rebase beta pr-${pr.number}`.nothrow()
if (rebase.exitCode !== 0) {
console.log(` Rebase failed for PR #${pr.number} (has conflicts)`)
await $`git rebase --abort`.nothrow()
await $`git checkout beta`.nothrow()
skipped.push({ number: pr.number, reason: "Rebase failed (conflicts)" })
continue
}
// Move rebased commits to pr-${pr.number} branch and checkout back to beta
await $`git checkout -B pr-${pr.number}`.nothrow()
await $`git checkout beta`.nothrow()
console.log(` Successfully rebased PR #${pr.number}`)
// Now squash merge the rebased PR
// Try to squash merge the PR directly
console.log(` Attempting to merge PR #${pr.number}...`)
const merge = await $`git merge --squash pr-${pr.number}`.nothrow()
if (merge.exitCode !== 0) {
console.log(` Squash merge failed for PR #${pr.number}`)