From 4743865f46dc9ed46720e593c5c9724350d0c9ce Mon Sep 17 00:00:00 2001 From: GraysonTinker <146041509+GraysonTinker@users.noreply.github.com> Date: Fri, 5 Jun 2026 05:24:19 -0400 Subject: [PATCH] ci/github-script/prepare: qualify recommendation to retarget from nixos-* --- ci/github-script/prepare.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ci/github-script/prepare.js b/ci/github-script/prepare.js index 7543374dfaa6a..e4e86cf3dd3d9 100644 --- a/ci/github-script/prepare.js +++ b/ci/github-script/prepare.js @@ -41,11 +41,16 @@ module.exports = async ({ github, context, core, dry }) => { if (baseClassification.type.includes('channel')) { const { stable, version } = baseClassification - const correctBranch = stable ? `release-${version}` : 'master' + + let releaseStable = `release-*` + if (stable) { + releaseStable = `release-${version}` + } + const body = [ 'The `nixos-*` and `nixpkgs-*` branches are pushed to by the channel release script and should not be merged into directly.', '', - `Please target \`${correctBranch}\` instead.`, + `Make sure you know the [right base branch for your changes](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md#branch-conventions), then target \`${releaseStable}\` or \`master\` instead.`, ].join('\n') await postReview({ github, context, core, dry, body, reviewKey })