免互動安裝GCompris Educational Software、解除安裝,以及在部署工具中偵測安裝狀態所用的指令。只列出確定可用的指令:來自資訊清單,或是安裝程式技術的官方預設參數。
相關教學: 靜默安裝參數總整理:MSI、NSIS、Inno Setup · 用登錄檔或PowerShell解除安裝程式
使用winget
PowerShell
winget install --id KDE.GCompris -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id KDE.GCompris -e --silentwinget uninstall --id KDE.GCompris -e --silent依安裝檔
64位元 · EXE(NSIS) · 所有使用者
靜默安裝
gcompris-teachers-26.2-win64-gcc.exe /S自訂安裝資料夾
gcompris-teachers-26.2-win64-gcc.exe /S /D=C:\Apps\gcompris-educational-software- 解除安裝登錄機碼
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\GCompris-Teachers
64位元 · MSI · 所有使用者
靜默安裝
msiexec /i gcompris-qt-26.2-win64-gcc.msi /qn /norestart寫入記錄檔
msiexec /i gcompris-qt-26.2-win64-gcc.msi /qn /norestart /l*v "%TEMP%\gcompris-educational-software-install.log"解除安裝
msiexec /x {67197195-9B91-4202-928C-AC7145EFBD9D} /qn /norestart- MSI產品代碼
- {67197195-9B91-4202-928C-AC7145EFBD9D}
- 解除安裝登錄機碼
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{67197195-9B91-4202-928C-AC7145EFBD9D}
- UpgradeCode
- {1902A562-DA6F-4E3D-A56F-1B1D4273C724}
PowerShell:下載、驗證、安裝
下載官方檔案,驗證SHA256後靜默安裝。
install-gcompris-educational-software.ps1
$url = 'https://download.kde.org/stable/gcompris/qt/windows/gcompris-teachers-26.2-win64-gcc.exe'
$sha256 = 'D98510A2737D1AF2576356B43561FAF09CF93E7C069ACE6542D141CFCB0D315F'
$file = Join-Path $env:TEMP 'gcompris-teachers-26.2-win64-gcc.exe'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process -FilePath $file -ArgumentList '/S' -Wait install-gcompris-educational-software.ps1
$url = 'https://download.kde.org/stable/gcompris/qt/windows/gcompris-qt-26.2-win64-gcc.msi'
$sha256 = '61CEC34B90D5BD4058DAAC225882CFBF2119CA26E6BAF0B7F38CB0F981E6F72E'
$file = Join-Path $env:TEMP 'gcompris-qt-26.2-win64-gcc.msi'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process msiexec.exe -ArgumentList '/i', ('"{0}"' -f $file), '/qn', '/norestart' -Wait