Kommandon för att installera Subsurface utan frågor, ta bort programmet igen och identifiera det i distributionsverktyg. Ett kommando visas bara när det är säkert: från manifestet eller som installationsteknikens dokumenterade standard.
Relaterad guide: Parametrar för tyst installation: MSI, NSIS, Inno · Avinstallera program via registret eller PowerShell
Med winget
PowerShell
winget install --id Subsurface.Subsurface -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id Subsurface.Subsurface -e --silentwinget uninstall --id Subsurface.Subsurface -e --silentPer installationsfil
64-bitars · EXE (NSIS)
Tyst installation
subsurface-6.0.5504-CICD-release-installer.exe /SEgen mapp
subsurface-6.0.5504-CICD-release-installer.exe /S /D=C:\Apps\subsurfacePowerShell: ladda ner, kontrollera, installera
Laddar ner den officiella filen, kontrollerar dess SHA256 och installerar tyst.
install-subsurface.ps1
$url = 'https://subsurface-divelog.org/downloads/subsurface-6.0.5504-CICD-release-installer.exe'
$sha256 = 'C23CC1421141D271FA4D7E624F30359F047842E75843375264275ABB55AD1795'
$file = Join-Path $env:TEMP 'subsurface-6.0.5504-CICD-release-installer.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