mirror of
https://github.com/servo/servo.git
synced 2025-09-30 16:49:16 +01:00
Abstract platform-specific workflows into separate files
This commit is contained in:
parent
55587bb92d
commit
1a84fcc9e1
5 changed files with 405 additions and 265 deletions
62
.github/workflows/windows.yml
vendored
Normal file
62
.github/workflows/windows.yml
vendored
Normal file
|
@ -0,0 +1,62 @@
|
|||
name: Windows workflow
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
layout:
|
||||
required: true
|
||||
type: string
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
layout:
|
||||
required: true
|
||||
type: choice
|
||||
options: ["2013", "2020"]
|
||||
push:
|
||||
branches: ["try-windows"]
|
||||
|
||||
env:
|
||||
RUST_BACKTRACE: 1
|
||||
SHELL: /bin/bash
|
||||
LAYOUT: "${{ contains(inputs.layout, '2020') && 'layout-2020' || 'layout-2013' }}"
|
||||
|
||||
jobs:
|
||||
build-win:
|
||||
name: Build
|
||||
runs-on: windows-2022
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 2
|
||||
- name: Copy to C drive
|
||||
run: cp D:\a C:\ -Recurse
|
||||
- name: Bootstrap
|
||||
working-directory: "C:\\a\\${{ github.event.repository.name }}\\${{ github.event.repository.name }}"
|
||||
run: |
|
||||
python -m pip install --upgrade pip virtualenv
|
||||
python mach fetch
|
||||
- name: Release build
|
||||
working-directory: "C:\\a\\${{ github.event.repository.name }}\\${{ github.event.repository.name }}"
|
||||
run: python mach build --release --media-stack=dummy --with-${{ env.LAYOUT }}
|
||||
- name: Unit tests
|
||||
working-directory: "C:\\a\\${{ github.event.repository.name }}\\${{ github.event.repository.name }}"
|
||||
run: python mach test-unit --release --with-${{ env.LAYOUT }}
|
||||
- name: Smoketest
|
||||
working-directory: "C:\\a\\${{ github.event.repository.name }}\\${{ github.event.repository.name }}"
|
||||
run: python mach smoketest --angle
|
||||
|
||||
build_result:
|
||||
name: homu build finished
|
||||
runs-on: ubuntu-latest
|
||||
if: always()
|
||||
# needs all build to detect cancellation
|
||||
needs:
|
||||
- "build-win"
|
||||
|
||||
steps:
|
||||
- name: Mark the job as successful
|
||||
run: exit 0
|
||||
if: ${{ !contains(join(needs.*.result, ','), 'failure') && !contains(join(needs.*.result, ','), 'cancelled') }}
|
||||
- name: Mark the job as unsuccessful
|
||||
run: exit 1
|
||||
if: contains(join(needs.*.result, ','), 'failure') || contains(join(needs.*.result, ','), 'cancelled')
|
Loading…
Add table
Add a link
Reference in a new issue