fixup workflow references - remove main #1
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Benchmarks | ||
on: | ||
workflow_call: | ||
inputs: | ||
benchmark_package_path: | ||
type: string | ||
description: "Path to the directory containing the benchmarking package. Defaults to ." | ||
default: "." | ||
swift_package_arguments: | ||
type: string | ||
description: "Arguments to the switch package command invocation e.g. `--disable-sandbox`" | ||
linux_5_9_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.9 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_5_10_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.10 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 6.0 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly 6.0 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_main_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly main Swift version matrix job. Defaults to true." | ||
default: true | ||
windows_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Windows 6.0 Swift version matrix job. Defaults to true." | ||
default: false | ||
windows_nightly_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Windows nightly 6.0 Swift version matrix job. Defaults to true." | ||
default: false | ||
windows_nightly_main_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Windows nightly main Swift version matrix job. Defaults to true." | ||
default: false | ||
jobs: | ||
construct-matrix: | ||
name: Construct Benchmarks matrix | ||
runs-on: ubuntu-latest | ||
outputs: | ||
benchmarks-matrix: '${{ steps.generate-matrix.outputs.benchmarks-matrix }}' | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
persist-credentials: false | ||
- id: generate-matrix | ||
run: echo "benchmarks-matrix=$(./scripts/generate_matrix.sh)" >> "$GITHUB_OUTPUT" | ||
env: | ||
MATRIX_LINUX_COMMAND: "swift package --package-path ${{ inputs.benchmark_package_path }} ${{ inputs.swift_package_arguments }} benchmark baseline check --check-absolute-path ${{ inputs.benchmark_package_path }}/Thresholds/${SWIFT_VERSION}/" | ||
MATRIX_LINUX_SETUP_COMMAND: "apt-get update -y -q && apt-get install -y -q libjemalloc-dev" | ||
MATRIX_LINUX_5_9_ENABLED: ${{ inputs.linux_5_9_enabled }} | ||
MATRIX_LINUX_5_10_ENABLED: ${{ inputs.linux_5_10_enabled }} | ||
MATRIX_LINUX_6_0_ENABLED: ${{ inputs.linux_6_0_enabled }} | ||
MATRIX_LINUX_NIGHTLY_6_0_ENABLED: ${{ inputs.linux_nightly_6_0_enabled }} | ||
MATRIX_LINUX_NIGHTLY_MAIN_ENABLED: ${{ inputs.linux_nightly_main_enabled }} | ||
benchmarks: | ||
name: Benchmarks | ||
needs: construct-matrix | ||
# Workaround https://github.com/nektos/act/issues/1875 | ||
uses: apple/swift-nio/.github/workflows/swift_test_matrix.yml | ||
with: | ||
name: "Benchmarks" | ||
matrix_string: '${{ needs.construct-matrix.outputs.benchmarks-matrix }}' |