-
Notifications
You must be signed in to change notification settings - Fork 42
ci: Test all R versions on branches that start with cran- #822
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -133,8 +133,12 @@ jobs: | |||||
| shell: bash | ||||||
|
|
||||||
| - id: versions-matrix | ||||||
| # Only run for pull requests if the base repo is different from the head repo, not for workflow_dispatch if not requested, always run for other events | ||||||
| if: (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.repository) && (github.event_name != 'workflow_dispatch' || inputs.versions-matrix) | ||||||
| # Only run for: | ||||||
| # - pull requests if the base repo is different from the head repo and the branch name does not start with "cran-" | ||||||
| # Do not run for: | ||||||
| # - workflow_dispatch if not requested | ||||||
| # Always run for other events. | ||||||
| if: (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.repository || startsWith(github.head_ref, 'cran-')) && (github.event_name != 'workflow_dispatch' || inputs.versions-matrix) | ||||||
| uses: ./.github/workflows/versions-matrix | ||||||
|
|
||||||
| - id: dep-suggests-matrix | ||||||
|
|
@@ -285,7 +289,7 @@ jobs: | |||||
|
|
||||||
| runs-on: ${{ matrix.os }} | ||||||
|
|
||||||
| if: ${{ needs.rcc-smoke.outputs.versions-matrix != '' && (github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.run-rcc-full)) }} | ||||||
| if: ${{ needs.rcc-smoke.outputs.versions-matrix != '' }} | ||||||
|
||||||
| if: ${{ needs.rcc-smoke.outputs.versions-matrix != '' }} | |
| if: ${{ needs.rcc-smoke.outputs.versions-matrix != '' && (github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.run-rcc-full)) }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The comment incorrectly describes the condition. It states "pull requests if the base repo is different from the head repo and the branch name does not start with 'cran-'", but the logic uses OR, not AND. The step actually runs for pull requests when EITHER the repos are different (external PR) OR the branch starts with 'cran-' (internal or external). The comment should be updated to accurately reflect that for pull requests, the step runs when: (1) it's an external PR from any branch, OR (2) the branch name starts with 'cran-' regardless of whether it's internal or external.