Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This will reduce the amount of pipelines executed in PRs to once instead of twice due to two targets matching previously in PRs.
Overview
When running pipelines on existing Pull Requests, it's very likely that the testing pipelines will be executed twice. That is becuase both
push
andpull_request
criteria match when pushing new code on the branch that has an open Pull Request.This PR adjusts the
push
target to only be executed onmain
branch to reduce the amount of pipelines executed on Pull Requests. A similar thing has been done forload-secrets-action
's testing pipeline as part of 1Password/load-secrets-action#87, followed by 1Password/load-secrets-action#90.Type of change
Related Issue(s)
How To Test
Check that the pipeline will only execute the Test and Validate once from the
pull_request
target. Compare that with #505: