-
Notifications
You must be signed in to change notification settings - Fork 374
/
chocolateyInstall.ps1
39 lines (30 loc) · 1.6 KB
/
chocolateyInstall.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
$ErrorActionPreference = 'Stop'
$toolsPath = Split-Path $MyInvocation.MyCommand.Definition
. $toolsPath\helpers.ps1
Close-VSCodeInsiders
$pp = Get-PackageParameters
function Get-MergeTasks {
$t = "!runCode"
$t += ', ' + '!' * $pp.NoDesktopIcon + 'desktopicon'
$t += ', ' + '!' * $pp.NoQuicklaunchIcon + 'quicklaunchicon'
$t += ', ' + '!' * $pp.NoContextMenuFiles + 'addcontextmenufiles'
$t += ', ' + '!' * $pp.NoContextMenuFolders + 'addcontextmenufolders'
$t += ', ' + '!' * $pp.DontAssociateWithFiles + 'associatewithfiles'
$t += ', ' + '!' * $pp.DontAddToPath + 'addtopath'
Write-Host "Merge Tasks: $t"
$t
}
$packageArgs = @{
packageName = "$env:ChocolateyPackageName"
fileType = 'exe'
url = 'https://az764295.vo.msecnd.net/insider/835ace5796cec0ed19a7eec119b26b57220b0f1a/VSCodeSetup-ia32-1.72.0-insider.exe'
url64bit = 'https://az764295.vo.msecnd.net/insider/835ace5796cec0ed19a7eec119b26b57220b0f1a/VSCodeSetup-x64-1.72.0-insider.exe'
softwareName = 'Microsoft Visual Studio Code Insiders'
checksum = '3aed4b091956d4599b2dd65ac3a858ac617a34849b457c1e327d039cf52d7c2f69521dce0b4dcdbecee7f13122e5462753e9bb5b23762e9ff7243fb85741ec87'
checksumType = 'sha512'
checksum64 = '131e7529d06e60e4f656d2c6b01ee9d3ae1e15a7e7a24ba3d61a63d505fd5823ae32990e45f26bf7528d7a1f40096b63e137c0806650c1b502fd0c520a033205'
checksumType64 = 'sha512'
silentArgs = '/verysilent /suppressmsgboxes /mergetasks="{0}" /log="{1}\install.log"' -f (Get-MergeTasks), (Get-PackageCacheLocation)
validExitCodes = @(0, 3010, 1641)
}
Install-ChocolateyPackage @packageArgs