Skip to content

chore(ci): Restrict trigger push branch for GitHub Workflow - #4458

Merged
lidavidm merged 1 commit into
apache:mainfrom
apupier:restrictTriggerPushForGitHubWorkflows
Jul 2, 2026
Merged

chore(ci): Restrict trigger push branch for GitHub Workflow#4458
lidavidm merged 1 commit into
apache:mainfrom
apupier:restrictTriggerPushForGitHubWorkflows

Conversation

@apupier

@apupier apupier commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Feature branches rarely need their own CI runs: the code is already tested when a pull request is opened against a release branch. If the push trigger has no branch restriction and pull_request is also configured, every push to a branch with an open PR runs the workflow twice: once for the push and once for the PR synchronisation.

Always give the push trigger an explicit list of branches: this stops branches created from a release branch from inheriting its workflow runs.

see https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=430408443#GitHubActionsRecommendedPractices-Restrictthepushtriggertospecificbranches

@apupier
apupier force-pushed the restrictTriggerPushForGitHubWorkflows branch from 0c73392 to 52c1f60 Compare July 2, 2026 08:51
Feature branches rarely need their own CI runs: the code is already
tested when a pull request is opened against a release branch. If the
push trigger has no branch restriction and pull_request is also
configured, every push to a branch with an open PR runs the workflow
twice: once for the push and once for the PR synchronisation.

Always give the push trigger an explicit list of branches: this stops
branches created from a release branch from inheriting its workflow
runs.

see https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=430408443#GitHubActionsRecommendedPractices-Restrictthepushtriggertospecificbranches

Signed-off-by: Aurélien Pupier <apupier@ibm.com>
@apupier
apupier force-pushed the restrictTriggerPushForGitHubWorkflows branch from 52c1f60 to 9c3c9b4 Compare July 2, 2026 09:03
@apupier apupier changed the title Restrict trigger push branch for GitHub Workflow chore(ci): Restrict trigger push branch for GitHub Workflow Jul 2, 2026

@lidavidm lidavidm left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@lidavidm
lidavidm merged commit 21cd016 into apache:main Jul 2, 2026
15 of 17 checks passed
@apupier
apupier deleted the restrictTriggerPushForGitHubWorkflows branch July 3, 2026 06:51
@lidavidm lidavidm added this to the ADBC Libraries 24 milestone Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants