cc-switch-remoteを確認画面なしでインストール・アンインストールし、展開ツールで検出するためのコマンドです。マニフェストの記載か、インストーラー技術の既定値として確実なコマンドだけを表示しています。
関連ガイド: サイレントインストールのオプション一覧 · レジストリとPowerShellでアンインストールする方法
wingetを使う
PowerShell
winget install --id zz920.cc-switch-remote -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id zz920.cc-switch-remote -e --silentwinget uninstall --id zz920.cc-switch-remote -e --silentインストーラー別
64ビット · EXE(NSIS) · 現在のユーザー
サイレントインストール
cc-switch-remote_3.20.2_x64-setup.exe /Sインストール先を指定
cc-switch-remote_3.20.2_x64-setup.exe /S /D=C:\Apps\cc-switch-remote- アンインストール用レジストリキー
- HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\cc-switch-remote
- インストール先フォルダー
- %LocalAppData%\cc-switch-remote
PowerShell:ダウンロード・検証・インストール
公式ファイルをダウンロードし、SHA256を検証してからサイレントインストールします。
install-cc-switch-remote.ps1
$url = 'https://github.com/zz920/cc-switch-remote/releases/download/v3.20.2-r1/cc-switch-remote_3.20.2_x64-setup.exe'
$sha256 = 'E142A66645804B159E10321D88F5E3A8E290730BDAEB7CAB552BB82732D1EBBF'
$file = Join-Path $env:TEMP 'cc-switch-remote_3.20.2_x64-setup.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