Commands for installing ggsql without prompts, removing it again and detecting it from deployment tools. A command is shown only when it is certain: from the manifest or the installer technology’s documented default.
Related guide: Silent install switches: MSI, NSIS, Inno Setup · Uninstall a program with the registry or PowerShell
By installer
64-bit · MSI
Silent install
msiexec /i ggsql_0.5.2_x64_en-US.msi /qn /norestartWrite a log
msiexec /i ggsql_0.5.2_x64_en-US.msi /qn /norestart /l*v "%TEMP%\ggsql-install.log"PowerShell: download, verify, install
Downloads the official file, checks its SHA256 and installs it silently.
install-ggsql.ps1
$url = 'https://github.com/posit-dev/ggsql/releases/download/v0.5.2/ggsql_0.5.2_x64_en-US.msi'
$sha256 = '04E54D1722F7AB88C41E74698617E0A673FEFB3BC3CB6768D3BD79401506D083'
$file = Join-Path $env:TEMP 'ggsql_0.5.2_x64_en-US.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