run CI on all PR branches (#282)
This is a follow-up to https://github.com/dart-lang/tools/pull/280#issuecomment-2189941102. In summary, we only run CI checks on PRs against the main branch. However, in cases where an older major version of a package needs to be patched, it doesn't make sense to PR against main. CI won't run for these PRs, but it probably should.
This updates our GitHub CI configs to run checks against PRs against any branch.
---
<details>
<summary>Contribution guidelines:</summary><br>
- See our [contributor guide](https://github.com/dart-lang/.github/blob/main/CONTRIBUTING.md) for general expectations for PRs.
- Larger or significant changes should be discussed in an issue before creating a PR.
- Contributions to our repos should follow the [Dart style guide](https://dart.dev/guides/language/effective-dart) and use `dart format`.
- Most changes should add an entry to the changelog and may need to [rev the pubspec package version](https://github.com/dart-lang/sdk/blob/main/docs/External-Package-Maintenance.md#making-a-change).
- Changes to packages require [corresponding tests](https://github.com/dart-lang/.github/blob/main/CONTRIBUTING.md#Testing).
Note that many Dart repos have a weekly cadence for reviewing PRs - please allow for some latency before initial review feedback.
</details>
diff --git a/.github/workflows/cli_config.yml b/.github/workflows/cli_config.yml
index 62b7dd9..ccc2ffe 100644
--- a/.github/workflows/cli_config.yml
+++ b/.github/workflows/cli_config.yml
@@ -3,7 +3,6 @@
on:
pull_request:
- branches: [main]
paths:
- ".github/workflows/cli_config.yml"
- "pkgs/cli_config/**"
diff --git a/.github/workflows/extension_discovery.yml b/.github/workflows/extension_discovery.yml
index ce3a231..d9c1407 100644
--- a/.github/workflows/extension_discovery.yml
+++ b/.github/workflows/extension_discovery.yml
@@ -3,7 +3,6 @@
on:
pull_request:
- branches: [ main ]
paths:
- '.github/workflows/unified_analytics.yml'
- 'pkgs/extension_discovery/**'
diff --git a/.github/workflows/graphs.yml b/.github/workflows/graphs.yml
index cebea57..f467a7f 100644
--- a/.github/workflows/graphs.yml
+++ b/.github/workflows/graphs.yml
@@ -3,13 +3,12 @@
permissions: read-all
on:
- # Run CI on pushes to the main branch, and on PRs against main.
- push:
- branches: [ main ]
+ # Run CI on all PRs (against any branch) and on pushes to the main branch.
+ pull_request:
paths:
- '.github/workflows/graphs.yml'
- 'pkgs/graphs/**'
- pull_request:
+ push:
branches: [ main ]
paths:
- '.github/workflows/graphs.yml'
diff --git a/.github/workflows/unified_analytics.yml b/.github/workflows/unified_analytics.yml
index 6fe64bb..47a4516 100644
--- a/.github/workflows/unified_analytics.yml
+++ b/.github/workflows/unified_analytics.yml
@@ -3,7 +3,6 @@
on:
pull_request:
- branches: [ main ]
paths:
- '.github/workflows/unified_analytics.yml'
- 'pkgs/unified_analytics/**'