Skip to content

Instantly share code, notes, and snippets.

@gerane
Created October 6, 2016 21:08
Show Gist options
  • Save gerane/b5d787f53fd8e19b397b951f603d290e to your computer and use it in GitHub Desktop.
Save gerane/b5d787f53fd8e19b397b951f603d290e to your computer and use it in GitHub Desktop.
$loadInf = '@
[Setup]
Lang=english
Dir=C:\Program Files (x86)\Microsoft VS Code Insiders
Group=Visual Studio Code Insiders
NoIcons=0
Tasks=desktopicon,addcontextmenufiles,addcontextmenufolders,addtopath
@'
$exePath = "${env:TEMP}\Insiders.exe"
$infPath = "${env:TEMP}\load.inf"
$loadInf | Out-File $infPath
Invoke-WebRequest -Uri 'https://go.microsoft.com/fwlink/?LinkId=723965' -OutFile $exePath
Start-Process -FilePath $exePath -ArgumentList "/VERYSILENT /LOADINF=${infPath}" -Wait
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment