@@ -142,34 +142,12 @@ jobs:
142142 wget -P .linuxdeploy-bin https://github.com/AppImage/appimagetool/releases/latest/download/appimagetool-$MAPPED_RUNNER_ARCH.AppImage
143143 chmod +x .linuxdeploy-bin/*
144144 if : runner.os == 'Linux'
145- - name : Remove pre-installed Python from PATH (PowerShell)
146- shell : pwsh
147- run : |
148- $pythonPath = (Get-Command python).Source
149- Write-Host "Found python at $pythonPath"
150-
151- $pythonDir = Split-Path $pythonPath
152- Write-Host "Python directory: $pythonDir"
153-
154- # Filter out $pythonDir from $env:Path
155- $newPath = ($env:Path -split ';' | Where-Object { $_ -notlike "$pythonDir*" }) -join ';'
156- Write-Host "New PATH: $newPath"
157-
158- # Export cleaned PATH to GitHub Actions environment
159- "PATH=$newPath" >> $env:GITHUB_ENV
160- if : matrix.tag == 'win7'
161145 - name : Set up Python for Windows7
162- shell : cmd
163- run : |
164- curl -L -o python-%PYTHON_WIN7_VERSION%-amd64-full.exe https://github.com/adang1345/PythonWin7/raw/refs/heads/master/%PYTHON_WIN7_VERSION%/python-%PYTHON_WIN7_VERSION%-amd64-full.exe
165- start /wait python-%PYTHON_WIN7_VERSION%-amd64-full.exe /quiet InstallAllUsers=1 PrependPath=1 Include_launcher=1
166- echo C:/Program Files/%PYTHON_WIN7_VERSION_MAJOR% >> %GITHUB_PATH%
167- echo C:/Program Files/%PYTHON_WIN7_VERSION_MAJOR%/Scripts >> %GITHUB_PATH%
168- if : matrix.tag == 'win7'
169- - name : Add Python for Windows7 to Path
170- run : |
171- echo "C:/Program Files/$PYTHON_WIN7_VERSION_MAJOR" >> $GITHUB_PATH
172- echo "C:/Program Files/$PYTHON_WIN7_VERSION_MAJOR/Scripts" >> $GITHUB_PATH
146+ uses : LorenEteval/setup-python-win7@v1
147+ with :
148+ python-version : ${{ matrix.python-version }}
149+ # Support Windows ARM64 build
150+ architecture : ${{ runner.arch == 'ARM64' && 'arm64' || 'amd64' }}
173151 if : matrix.tag == 'win7'
174152 - name : Set up Python
175153 uses : actions/setup-python@v5
@@ -191,7 +169,7 @@ jobs:
191169 mkdir plugins
192170 mv imageformats platforms styles plugins
193171 cd ..
194- cp -r qt6_x64_to_run_on_windows7/* "C:/Program Files/$PYTHON_WIN7_VERSION_MAJOR /Lib/site-packages/PySide6/"
172+ cp -r qt6_x64_to_run_on_windows7/* "$PYTHON_WIN7_HOME /Lib/site-packages/PySide6/"
195173 if : matrix.tag == 'win7'
196174 - name : Download Python dependencies & latest asset files
197175 run : |
0 commit comments