Skip to content

Commit

Permalink
feat: pre-publish job adjusted to triggering event (#212)
Browse files Browse the repository at this point in the history
This PR regards https://splunk.atlassian.net/browse/ADDON-67617
It introduces dynamic change of pre-publish job which was necessary to
avoid confusion while creating PR towards main branch having had pushed
to develop branch.

tests: 
- pr: splunk/splunk-add-on-for-mysql#464
- push to develop workflow (name has been changed):
https://github.com/splunk/splunk-add-on-for-mysql/actions/runs/7399079510
- pr to main workflow (name remains intact):
https://github.com/splunk/splunk-add-on-for-mysql/actions/runs/7399125452
  • Loading branch information
kdoroszko-splunk authored Jan 4, 2024
1 parent 682b7f1 commit 1e65154
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/reusable-build-test-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2671,6 +2671,10 @@ jobs:
pre-publish:
if: ${{ !cancelled() }}
# The following line will rename 'pre-publish' to 'pre-publish-not_main_pr' when PR is created towards main branch
# It is necessary to avoid confusion caused by githubactions considering pre-publish for both push to develop branch
# and pull_request to main branch events.
name: ${{ github.event_name == 'pull_request' && github.base_ref == 'main' && 'pre-publish' || 'pre-publish-not_main_pr' }}
needs:
- meta
- compliance-copyrights
Expand Down

0 comments on commit 1e65154

Please sign in to comment.