Fuse compatible CPU complex operator applications #4506
This file contains hidden or 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
| # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. | |
| # SPDX-License-Identifier: Apache-2.0 | |
| name: Style | |
| permissions: | |
| contents: read | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| check-style: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| # Install clang-format-19 from LLVM (newer than the distro package) | |
| - name: Install clang-format | |
| run: | | |
| wget -O- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - | |
| sudo add-apt-repository 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-19 main' | |
| sudo apt-get update -q | |
| sudo apt-get install -y clang-format-19 | |
| - name: Check style | |
| run: | | |
| ./scripts/format-source --clang-format clang-format-19 | |
| if [[ `git status -s | wc -l` -ne 0 ]]; then | |
| echo 'Error: Commit is not formatted!' | |
| echo 'Run '\`'./scripts/format-source'\`' in the source root directory' | |
| echo 'Summary of required changes:' | |
| echo "`git diff --stat`" | |
| echo 'Repository status:' | |
| echo "`git status`" | |
| exit 1 | |
| else | |
| echo 'Commit is correctly formatted' | |
| exit 0 | |
| fi | |
| check-config: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Check JSON Schema | |
| run: | | |
| OUTPUT=$(find examples -name *.json -maxdepth 2 -print0 | xargs -0 -n1 ./scripts/validate-config) | |
| if echo $OUTPUT | grep -q 'Validation failed'; then | |
| echo 'Error: Configuration file validation failed!' | |
| echo 'Summary of output:' | |
| echo $OUTPUT | |
| exit 1 | |
| else | |
| echo 'Configuration file validation passed' | |
| exit 0 | |
| fi | |
| check-schema-version: | |
| runs-on: ubuntu-latest | |
| # Only meaningful for pull requests, where there is a base branch to diff against. | |
| if: github.event_name == 'pull_request' | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Check schema version bump | |
| run: | | |
| git fetch --no-tags --depth=1 origin "${GITHUB_BASE_REF}" | |
| ./scripts/check-schema-version "origin/${GITHUB_BASE_REF}" | |
| check-changelog-schema-versions: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Check changelog schema versions | |
| run: ./scripts/check-changelog-schema-versions | |
| check-tests-tags: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Check test tags | |
| run: ./scripts/check-test-tags test/unit | |
| - name: Test CMake architecture helpers | |
| run: cmake -P cmake/tests/MultiArchitecture.cmake | |
| check-license: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: viperproject/check-license-header@v2 | |
| with: | |
| config: .github/license-check/config.json | |
| strict: false | |
| # Unit tests for the trusted container-publish scripts (.github/publish_containers/). | |
| # These guard the publish authorization decision, so they must run on every | |
| # change. Stdlib unittest only — no dependencies to install. | |
| check-publish-scripts: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Run publish script tests | |
| run: python3 -m unittest discover -s .github/publish_containers -p 'test_*.py' -v |