免互動安裝OpenChatCut、解除安裝,以及在部署工具中偵測安裝狀態所用的指令。只列出確定可用的指令:來自資訊清單,或是安裝程式技術的官方預設參數。
相關教學: 靜默安裝參數總整理:MSI、NSIS、Inno Setup · 用登錄檔或PowerShell解除安裝程式
使用winget
PowerShell
winget install --id 0xsline.OpenChatCut -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id 0xsline.OpenChatCut -e --silentwinget uninstall --id 0xsline.OpenChatCut -e --silent依安裝檔
64位元 · EXE(NSIS) · 僅目前使用者
靜默安裝
OpenChatCut-0.2.17-x64.exe /S自訂安裝資料夾
OpenChatCut-0.2.17-x64.exe /S /D=C:\Apps\openchatcut- 解除安裝登錄機碼
- HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\4945e2ca-67f3-5a09-abd8-76f9f6a378c8
- 安裝資料夾
- %LocalAppData%\Programs\OpenChatCut
64位元 · EXE(NSIS) · 所有使用者
靜默安裝
OpenChatCut-0.2.17-x64.exe /S自訂安裝資料夾
OpenChatCut-0.2.17-x64.exe /S /D=C:\Apps\openchatcut- 解除安裝登錄機碼
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\4945e2ca-67f3-5a09-abd8-76f9f6a378c8
- 安裝資料夾
- %ProgramFiles%\OpenChatCut
PowerShell:下載、驗證、安裝
下載官方檔案,驗證SHA256後靜默安裝。
install-openchatcut.ps1
$url = 'https://github.com/0xsline/OpenChatCut/releases/download/v0.2.17/OpenChatCut-0.2.17-x64.exe'
$sha256 = '6E6A2D76F2D9BFCEB1782DDB1DBEF62D955CB55321AF18525A389FA16ABF9906'
$file = Join-Path $env:TEMP 'OpenChatCut-0.2.17-x64.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-openchatcut.ps1
$url = 'https://github.com/0xsline/OpenChatCut/releases/download/v0.2.17/OpenChatCut-0.2.17-x64.exe'
$sha256 = '6E6A2D76F2D9BFCEB1782DDB1DBEF62D955CB55321AF18525A389FA16ABF9906'
$file = Join-Path $env:TEMP 'OpenChatCut-0.2.17-x64.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