mirror of
https://github.com/shaka-project/shaka-packager.git
synced 2026-04-13 08:40:49 +00:00
It has been very, very annoying lately to have PRs get stuck in several loops of linter failures without finding out if the thing builds or passes tests. From now on, lint in parallel with everything else.
71 lines
1.9 KiB
YAML
71 lines
1.9 KiB
YAML
# Copyright 2022 Google LLC
|
|
#
|
|
# Use of this source code is governed by a BSD-style
|
|
# license that can be found in the LICENSE file or at
|
|
# https://developers.google.com/open-source/licenses/bsd
|
|
|
|
name: Build and Test PR
|
|
|
|
# Builds and tests on all combinations of OS, build type, and library type.
|
|
# Also builds the docs.
|
|
#
|
|
# Runs when a pull request is opened or updated.
|
|
#
|
|
# Can also be run manually for debugging purposes.
|
|
on:
|
|
pull_request:
|
|
types: [opened, synchronize, reopened]
|
|
workflow_dispatch:
|
|
inputs:
|
|
ref:
|
|
description: "The ref to build and test."
|
|
required: false
|
|
type: string
|
|
|
|
# If another instance of this workflow is started for the same PR, cancel the
|
|
# old one. If a PR is updated and a new test run is started, the old test run
|
|
# will be cancelled automatically to conserve resources.
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.event.number || inputs.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
settings:
|
|
name: Settings
|
|
uses: ./.github/workflows/settings.yaml
|
|
|
|
lint:
|
|
name: Lint
|
|
uses: ./.github/workflows/lint.yaml
|
|
with:
|
|
ref: ${{ inputs.ref || github.ref }}
|
|
|
|
build_and_test:
|
|
needs: [settings]
|
|
name: Build and test
|
|
uses: ./.github/workflows/build.yaml
|
|
with:
|
|
ref: ${{ inputs.ref || github.ref }}
|
|
self_hosted: ${{ needs.settings.outputs.self_hosted != '' }}
|
|
debug: ${{ needs.settings.outputs.debug != '' }}
|
|
|
|
build_docs:
|
|
needs: [settings]
|
|
name: Build docs
|
|
uses: ./.github/workflows/build-docs.yaml
|
|
with:
|
|
ref: ${{ inputs.ref || github.ref }}
|
|
debug: ${{ needs.settings.outputs.debug != '' }}
|
|
|
|
official_docker_image:
|
|
name: Official Docker image
|
|
uses: ./.github/workflows/build-docker.yaml
|
|
with:
|
|
ref: ${{ inputs.ref || github.ref }}
|
|
|
|
test_supported_linux_distros:
|
|
name: Test Linux distros
|
|
uses: ./.github/workflows/test-linux-distros.yaml
|
|
with:
|
|
ref: ${{ inputs.ref || github.ref }}
|