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