mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
ci: move code format check out of the main job/script (#1154)
A bit cleaner than the written-in-a-haste-to-get-ci-going-again current approach. Signed-off-by: Kevin Petit <kevin.petit@arm.com>
This commit is contained in:
21
.github/workflows/presubmit.yml
vendored
21
.github/workflows/presubmit.yml
vendored
@@ -6,7 +6,6 @@ jobs:
|
||||
name: Build ${{ matrix.os }} ${{ matrix.name }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
env:
|
||||
JOB_CHECK_FORMAT: ${{ matrix.format }}
|
||||
JOB_ARCHITECTURE: ${{ matrix.arch }}
|
||||
JOB_ENABLE_GL: ${{ matrix.gl }}
|
||||
strategy:
|
||||
@@ -17,10 +16,6 @@ jobs:
|
||||
- os: ubuntu-20.04
|
||||
mainmatrix: true
|
||||
gl: 1
|
||||
- os: ubuntu-20.04
|
||||
mainmatrix: false
|
||||
name: Format
|
||||
format: 1
|
||||
- os: ubuntu-20.04
|
||||
mainmatrix: false
|
||||
name: Arm
|
||||
@@ -30,11 +25,17 @@ jobs:
|
||||
name: AArch64
|
||||
arch: aarch64
|
||||
steps:
|
||||
- name: Setup
|
||||
run: if [[ "${{matrix.format}}" == "1" ]]; then sudo apt install -y clang-format; fi
|
||||
- uses: actions/checkout@v2
|
||||
- name: Build
|
||||
run: ./presubmit.sh
|
||||
formatcheck:
|
||||
name: Check code format
|
||||
runs-on: ubuntu-20.04
|
||||
steps:
|
||||
- name: Install packages
|
||||
run: sudo apt install -y clang-format
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Build
|
||||
run: ./presubmit.sh
|
||||
|
||||
- name: Check code format
|
||||
run: ./check-format.sh
|
||||
|
||||
@@ -4,11 +4,6 @@ set -e
|
||||
|
||||
export TOP=$(pwd)
|
||||
|
||||
if [[ "${JOB_CHECK_FORMAT}" == "1" ]]; then
|
||||
./check-format.sh
|
||||
exit $?
|
||||
fi
|
||||
|
||||
TOOLCHAIN_URL_arm="https://releases.linaro.org/components/toolchain/binaries/7.5-2019.12/arm-linux-gnueabihf/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf.tar.xz"
|
||||
TOOLCHAIN_URL_aarch64="https://releases.linaro.org/components/toolchain/binaries/7.5-2019.12/aarch64-linux-gnu/gcc-linaro-7.5.0-2019.12-x86_64_aarch64-linux-gnu.tar.xz"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user