WinMemoryOptを確認画面なしでインストール・アンインストールし、展開ツールで検出するためのコマンドです。マニフェストの記載か、インストーラー技術の既定値として確実なコマンドだけを表示しています。
関連ガイド: サイレントインストールのオプション一覧 · レジストリとPowerShellでアンインストールする方法
wingetを使う
PowerShell
winget install --id Optico.WinMemoryOpt -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id Optico.WinMemoryOpt -e --silentwinget uninstall --id Optico.WinMemoryOpt -e --silentインストーラー別
64ビット · EXE(NSIS)
サイレントインストール
WinMemoryOpt-Setup-1.2.2.exe /Sインストール先を指定
WinMemoryOpt-Setup-1.2.2.exe /S /D=C:\Apps\winmemoryoptPowerShell:ダウンロード・検証・インストール
公式ファイルをダウンロードし、SHA256を検証してからサイレントインストールします。
install-winmemoryopt.ps1
$url = 'https://github.com/chienhaoc/WinMemoryOpt/releases/download/v1.2.2/WinMemoryOpt-Setup-1.2.2.exe'
$sha256 = 'BEC55DA9AAFBC20EAB94CDA67CAB54177380BE59295D5567D95517EC5269AA85'
$file = Join-Path $env:TEMP 'WinMemoryOpt-Setup-1.2.2.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