doc-execを確認画面なしでインストール・アンインストールし、展開ツールで検出するためのコマンドです。マニフェストの記載か、インストーラー技術の既定値として確実なコマンドだけを表示しています。
関連ガイド: サイレントインストールのオプション一覧 · レジストリとPowerShellでアンインストールする方法
wingetを使う
PowerShell
winget install --id combostrap.doc-exec -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id combostrap.doc-exec -e --silentwinget uninstall --id combostrap.doc-exec -e --silentインストーラー別
64ビット · MSI · 現在のユーザー
サイレントインストール
msiexec /i combostrap-doc-exec-1.1.0-jre-x64.msi /qn /norestartログを出力
msiexec /i combostrap-doc-exec-1.1.0-jre-x64.msi /qn /norestart /l*v "%TEMP%\doc-exec-install.log"- アンインストール用レジストリキー
- HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\doc-exec 1.1.0
PowerShell:ダウンロード・検証・インストール
公式ファイルをダウンロードし、SHA256を検証してからサイレントインストールします。
install-doc-exec.ps1
$url = 'https://github.com/combostrap/doc-exec/releases/download/v1.1.0/combostrap-doc-exec-1.1.0-jre-x64.msi'
$sha256 = '499BD76B10C72C6958A1627FEAC5E4F212FC823F836046C3170A0FC9AD6EEB3B'
$file = Join-Path $env:TEMP 'combostrap-doc-exec-1.1.0-jre-x64.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