cricut-design-space: Extract files directly instead of running installer
All checks were successful
/ Build-Chocolatey-Packages (push) Successful in 1m8s

This commit is contained in:
Adam Goldsmith 2024-12-16 13:29:26 -05:00
parent 65482920eb
commit 9b13e4c80c

View File

@ -1,39 +1,30 @@
$ErrorActionPreference = 'Stop';
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"
$installDir = "C:\Program Files (x86)\Cricut Design Space\"
$packageArgs = @{
packageName = $env:ChocolateyPackageName
unzipLocation = $toolsDir
fileType = 'EXE'
File = '\\ucs\software\CricutDesignSpace-Install-v8.60.67.exe'
softwareName = 'cricutdesignspace*'
checksum = '78b04935a1be4cef0e9f690a75b53c86c5783d8491760a5dada709544cf25d0c'
checksumType = 'sha256'
silentArgs = '/S'
validExitCodes= @(0)
Checksum = '78b04935a1be4cef0e9f690a75b53c86c5783d8491760a5dada709544cf25d0c'
ChecksumType = 'sha256'
UnzipLocation = $toolsDir
}
Install-ChocolateyPackage @packageArgs
Install-ChocolateyZipPackage @packageArgs
$innerPackageArgs = @{
File = "$(Join-Path $toolsDir '$PLUGINSDIR/app-32.7z')"
Destination = $installDir
}
Get-ChocolateyUnzip @innerPackageArgs
$shortcutArgs = @{
ShortcutFilePath = "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Cricut Design Space.lnk"
TargetPath = "$(Join-Path $installDir 'Cricut Design Space.exe')"
WorkingDirectory = $installDir
IconLocation = "$(Join-Path $installDir 'Cricut Design Space.exe')"
Description = "Cricut Design Space Application"
}
Install-ChocolateyShortcut @shortcutArgs