Auto merge of #29618 - servo:split-and-merge-workflows, r=jdm

Split quick check from pull request and rename WPT export actions

Split out the quick check GitHub action (which is really only meant for forks). This prevents the quick check from running twice for PRs from branches on the upstream repository. Also rename the WPT export action file to make it clearer that it runs for pull requests. This change also means we no longer trigger builds when simply editing pull request body or title.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #29603
- [x] These changes do not require tests because this is just a reorganization of the workflow files.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
This commit is contained in:
bors-servo 2023-04-12 03:53:32 +02:00 committed by GitHub
commit df83e2a998
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 30 additions and 3 deletions

View file

@ -1,4 +1,4 @@
name: WPT export
name: Pull request (WPT export)
on:
pull_request_target:
types: ['opened', 'synchronize', 'reopened', 'edited', 'closed']
@ -37,4 +37,4 @@ jobs:
run: servo/etc/ci/upstream-wpt-changes/upstream-wpt-changes.py
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
WPT_SYNC_TOKEN: ${{ secrets.WPT_SYNC_TOKEN }}
WPT_SYNC_TOKEN: ${{ secrets.WPT_SYNC_TOKEN }}

23
.github/workflows/pull-request.yml vendored Normal file
View file

@ -0,0 +1,23 @@
name: Pull request
on:
pull_request:
types: ['opened', 'synchronize']
branches: ["**"]
jobs:
build-linux:
name: Linux
if: github.repository == 'servo/servo'
uses: ./.github/workflows/linux.yml
with:
layout: '2013'
unit-tests: true
build-linux-layout-2020:
name: Linux (layout-2020)
if: github.repository == 'servo/servo'
uses: ./.github/workflows/linux.yml
with:
layout: '2020'
unit-tests: false

View file

@ -1,6 +1,8 @@
# This action is meant as a quick check to be run when pushing to
# branches on forks. This allows forks to test the build and unit
# tests automatically without opening a pull request.
name: Quick check
on:
pull_request:
push:
branches:
["**", "!master", "!auto", "!try", "!try-linux", "!try-mac", "!try-windows", "!try-wpt", "!dependabot/**"]
@ -8,6 +10,7 @@ on:
jobs:
build-linux:
name: Linux
if: github.repository != 'servo/servo' || github.event_name == 'workflow_dispatch'
uses: ./.github/workflows/linux.yml
with:
layout: '2013'
@ -15,6 +18,7 @@ jobs:
build-linux-layout-2020:
name: Linux (layout-2020)
if: github.repository != 'servo/servo' || github.event_name == 'workflow_dispatch'
uses: ./.github/workflows/linux.yml
with:
layout: '2020'