From 5ef3a41dc99524247110f7481d09076afc6eae6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20St=C3=B6neberg?= Date: Fri, 28 Jan 2022 19:44:39 +0100 Subject: [PATCH] cache Qt installation in Windows CI jobs (#3769) * CI-windows.yml: cache Qt installation * release-windows.yml: store Qt version in env * release-windows.yml: cache Qt installation --- .github/workflows/CI-windows.yml | 9 +++++++++ .github/workflows/release-windows.yml | 13 +++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/.github/workflows/CI-windows.yml b/.github/workflows/CI-windows.yml index 3f781f293..baa431afd 100644 --- a/.github/workflows/CI-windows.yml +++ b/.github/workflows/CI-windows.yml @@ -91,6 +91,14 @@ jobs: 7z x z3-%Z3_VERSION%-${{ matrix.arch }}-win.zip -oexternals -r -y || exit /b !errorlevel! move externals\z3-%Z3_VERSION%-${{ matrix.arch }}-win externals\z3 || exit /b !errorlevel! + - name: Cache Qt ${{ matrix.qt_ver }} + if: matrix.qt_ver != '' && matrix.arch == 'x64' + id: cache-qt + uses: actions/cache@v1 # not v2! + with: + path: ../Qt + key: Windows-QtCache-${{ matrix.qt_ver }}-qtcharts + # no 32-bit Qt available - name: Install Qt ${{ matrix.qt_ver }} if: matrix.qt_ver != '' && matrix.arch == 'x64' @@ -98,6 +106,7 @@ jobs: with: version: ${{ matrix.qt_ver }} modules: 'qtcharts' + cached: ${{ steps.cache-qt.outputs.cache-hit }} - name: Install missing Python packages if: matrix.qt_ver == '' diff --git a/.github/workflows/release-windows.yml b/.github/workflows/release-windows.yml index 4684c2e01..8fa744d92 100644 --- a/.github/workflows/release-windows.yml +++ b/.github/workflows/release-windows.yml @@ -27,6 +27,7 @@ jobs: PCRE_VERSION: 8.45 # see https://github.com/Z3Prover/z3/releases: Z3_VERSION: 4.8.10 + QT_VERSION: 5.15.2 steps: - uses: actions/checkout@v2 @@ -76,11 +77,19 @@ jobs: 7z x z3-%Z3_VERSION%-x64-win.zip -oexternals -r -y move externals\z3-%Z3_VERSION%-x64-win externals\z3 - - name: Install Qt + - name: Cache Qt ${{ env.QT_VERSION }} + id: cache-qt + uses: actions/cache@v1 # not v2! + with: + path: ../Qt + key: Windows-QtCache-${{ env.QT_VERSION }}-qtcharts-qthelp + + - name: Install Qt ${{ env.QT_VERSION }} uses: jurplel/install-qt-action@v2 with: - version: '5.15.2' + version: ${{ env.QT_VERSION }} modules: 'qtcharts qthelp' + cached: ${{ steps.cache-qt.outputs.cache-hit }} - name: Create .qm run: |