From 9fa7f2e4b63ac23ccae7077f5471e355e7dd71ca Mon Sep 17 00:00:00 2001 From: Anthony Bilinski Date: Thu, 23 Sep 2021 03:10:11 -0700 Subject: [PATCH] chore(CI): Split Win deps into their own job Previously, the four matrix Windows jobs would run in parallel and each build deps, which is redundant since both debug and release qTox use the same deps. Now, the win-deps job builds only the needed two versions of deps, and the four windows builds wait for it to complete before running in parallel. --- .github/workflows/test.yaml | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 2f78d4297..7ea1cd0aa 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -70,16 +70,14 @@ jobs: - uses: actions/checkout@v2 - name: Run run: ./flatpak/build-flatpak.sh - win: - name: Windows + win-deps: + name: Windows Deps runs-on: ubuntu-latest strategy: matrix: arch: [i686, x86_64] - type: [debug, release] env: BUILD__: ${{ matrix.arch }} - BTYPE__: ${{ matrix.type }} steps: - uses: actions/checkout@v2 - name: Cache dependencies @@ -98,6 +96,24 @@ jobs: run: | ./.travis/build-windows.sh "$BUILD__" "release" "cache/${BUILD__}" stage2 ls -al cache + win: + name: Windows + runs-on: ubuntu-latest + needs: win-deps + strategy: + matrix: + arch: [i686, x86_64] + type: [debug, release] + env: + BUILD__: ${{ matrix.arch }} + BTYPE__: ${{ matrix.type }} + steps: + - uses: actions/checkout@v2 + - name: Fetch cached dependencies + uses: actions/cache@v2 + with: + path: cache + key: deps-${{ matrix.arch }}-${{ hashFiles('windows/cross-compile/build.sh') }}-${{ hashFiles('.travis/build-windows.sh') }} - name: qTox build run: | ./.travis/build-windows.sh "$BUILD__" "$BTYPE__" "cache/${BUILD__}" stage3