From eec0bdcbb6b0b1c89a67d0f8601c2beeeb6f498d Mon Sep 17 00:00:00 2001 From: Alan Agius <17563226+alan-agius4@users.noreply.github.com> Date: Thu, 11 Sep 2025 12:02:18 +0000 Subject: [PATCH] build: create release branch from FETCH_HEAD (#63731) When creating the release branch, it should be based on the latest upstream changes to avoid building a release on a stale commit. PR Close #63731 --- devtools/tools/release.mts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devtools/tools/release.mts b/devtools/tools/release.mts index b2711cd69ab..67e42b67a5c 100644 --- a/devtools/tools/release.mts +++ b/devtools/tools/release.mts @@ -293,7 +293,7 @@ async function prepareReleasePullRequest(newVersion: string): Promise { console.log(chalk.blue('Creating release commit...')); const releaseBranch = `devtools-release-${newVersion}`; await exec(`git branch -D ${releaseBranch}`).catch(() => {}); - await exec(`git checkout -b ${releaseBranch}`); + await exec(`git checkout -b ${releaseBranch} FETCH_HEAD`); await exec(`git commit -m "${releaseCommitPrefix}${newVersion}" "${manifestPaths.join('" "')}"`); await exec(`git push origin ${releaseBranch} --force-with-lease`); console.log(chalk.green('Release branch pushed to your fork.'));