Spotifyを確認画面なしでインストール・アンインストールし、展開ツールで検出するためのコマンドです。マニフェストの記載か、インストーラー技術の既定値として確実なコマンドだけを表示しています。
関連ガイド: サイレントインストールのオプション一覧 · レジストリとPowerShellでアンインストールする方法
wingetを使う
PowerShell
winget install --id Spotify.Spotify -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id Spotify.Spotify -e --silentwinget uninstall --id Spotify.Spotify -e --silentインストーラー別
64ビット · EXE · 現在のユーザー
サイレントインストール
SpotifyFullSetupX64.exe /silent /skip-app-launch- アンインストール用レジストリキー
- HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Spotify
ARM64 · EXE · 現在のユーザー
サイレントインストール
SpotifyFullSetupARM64.exe /silent /skip-app-launch- アンインストール用レジストリキー
- HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Spotify
PowerShell:ダウンロード・検証・インストール
公式ファイルをダウンロードし、SHA256を検証してからサイレントインストールします。
install-spotify.ps1
$url = 'https://download.scdn.co/SpotifyFullSetupX64.exe'
$sha256 = 'E5CA46AD79DE202C8DEAF888C26F2A608B9E042142279E0690D589D80640591D'
$file = Join-Path $env:TEMP 'SpotifyFullSetupX64.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 '/silent /skip-app-launch' -Wait install-spotify.ps1
$url = 'https://download.scdn.co/SpotifyFullSetupARM64.exe'
$sha256 = '1AB0FF830A6996E69F8DB9CC5B7FB08BD6E87FC16E70642F8C5DFBE711EE948D'
$file = Join-Path $env:TEMP 'SpotifyFullSetupARM64.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 '/silent /skip-app-launch' -Wait