You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Skip update-codeql cron run when upgrade branch already exists
Adds a 'check-existing-branch' job that runs after detect-update and
gates the create-pr job. On scheduled (cron) runs, if the target
'codeql/upgrade-to-vX.Y.Z' branch already exists on origin, the rest
of the pipeline is skipped so peter-evans/create-pull-request does
not force-push over reviewer commits or follow-up fixes (such as
manually-applied lock-file refreshes).
The check is bypassed on workflow_dispatch so a maintainer can
always force a refresh by re-running the workflow manually.
if [ "${{ steps.check-branch.outputs.branch_exists }}" = "true" ]; then
160
+
echo "⏭️ Branch \`${BRANCH}\` already exists — skipping the rest of the pipeline to preserve any manual edits or review commits on it." >> $GITHUB_STEP_SUMMARY
161
+
echo "" >> $GITHUB_STEP_SUMMARY
162
+
echo "Trigger this workflow manually via \`workflow_dispatch\` to force a refresh." >> $GITHUB_STEP_SUMMARY
163
+
else
164
+
echo "▶️ Branch \`${BRANCH}\` does not exist — proceeding with the update pipeline." >> $GITHUB_STEP_SUMMARY
0 commit comments