Skip to content

Commit 1ee67d2

Browse files
authored
Fix Qt caching (flameshot-org#4008)
1 parent 58afdce commit 1ee67d2

File tree

2 files changed

+8
-21
lines changed

2 files changed

+8
-21
lines changed

.github/workflows/Windows-pack.yml

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,7 @@ jobs:
2828
name: VS 2022 ${{ matrix.config.arch }}-${{ matrix.type }}
2929
runs-on: windows-2025
3030
env:
31-
VCINSTALLDIR: C:/Program Files (x86)/Microsoft Visual Studio/2022/Enterprise/VC/
32-
Qt6_DIR: ${{ github.workspace }}\build\Qt\${{ matrix.qt_ver }}\${{ matrix.config.qt_arch_install }}\lib\cmake\Qt6\
33-
QTDIR: ${{ github.workspace }}\build\Qt\${{ matrix.qt_ver }}\${{ matrix.config.qt_arch_install }}\
31+
VCINSTALLDIR: C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC
3432
# 2025.02.14
3533
VCPKG_VERSION: d5ec528843d29e3a52d745a64b469f810b2cedbf
3634
VCPKG_PACKAGES: openssl-windows
@@ -101,21 +99,15 @@ jobs:
10199
vcpkgGitCommitId: ${{ env.VCPKG_VERSION }}
102100
vcpkgTriplet: ${{ matrix.config.vcpkg_triplet }}
103101

104-
- name: Cache Qt
105-
id: cache-qt
106-
uses: actions/cache@v4
107-
with:
108-
path: ./build/Qt/${{ matrix.qt_ver }}/${{ matrix.config.qt_arch_install }}
109-
key: ${{ runner.os }}-QtCache/${{ matrix.qt_ver }}/${{ matrix.config.qt_arch }}
110-
111102
- name: Install Qt
112103
uses: jurplel/install-qt-action@v4
113104
with:
114105
version: ${{ matrix.qt_ver }}
106+
cache: 'true'
107+
cache-key-prefix: install-qt-action-${{ matrix.qt_ver }}
115108
target: ${{ matrix.qt_target }}
116109
arch: ${{ matrix.config.qt_arch }}
117110
dir: '${{ github.workspace }}/build/'
118-
cached: ${{ steps.cache-qt.outputs.cache-hit }}
119111

120112
- name: Configure
121113
working-directory: build

.github/workflows/build_cmake.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,8 @@ jobs:
9898
artifact: "Windows-MSVC.tar.xz",
9999
os: windows-2022,
100100
cc: "cl", cxx: "cl",
101-
environment_script: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars64.bat"
101+
environment_script: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars64.bat",
102+
qt_ver: '6.9.1'
102103
}
103104

104105
steps:
@@ -109,20 +110,14 @@ jobs:
109110
run: |
110111
Remove-Item "$env:LOCALAPPDATA\Microsoft\WindowsApps\python*.exe" -Force -ErrorAction SilentlyContinue
111112
112-
- name: Cache Qt
113-
id: cache-qt
114-
uses: actions/cache@v4
115-
with:
116-
path: ./build/Qt/6.9.1
117-
key: ${{ runner.os }}-QtCache-6.9.1
118-
119113
- name: Install Qt
120114
uses: jurplel/install-qt-action@v4
121115
with:
122-
version: 6.9.1
116+
version: ${{ matrix.config.qt_ver }}
117+
cache: 'true'
118+
cache-key-prefix: install-qt-action-${{ matrix.config.qt_ver }}
123119
target: desktop
124120
dir: '${{ github.workspace }}/build/'
125-
cached: ${{ steps.cache-qt.outputs.cache-hit }}
126121

127122
- name: Configure
128123
working-directory: build

0 commit comments

Comments
 (0)