Skip to content

Commit

Permalink
AU: 1 updated - origin
Browse files Browse the repository at this point in the history
  • Loading branch information
Chocolatey committed Jan 30, 2018
1 parent 3b3c353 commit 7b4c370
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion automatic/origin/info
Original file line number Diff line number Diff line change
@@ -1 +1 @@
"f9c7cb51373c016e59567a1478544272-28"|10.5.8.17910
"dd23991ecdfe6933805d6f6c69d99dcb-14"|10.5.10.24870
2 changes: 1 addition & 1 deletion automatic/origin/origin.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
<metadata>
<id>origin</id>
<version>10.5.8.17910</version>
<version>10.5.10.24870</version>
<packageSourceUrl>https://github.com/AdmiringWorm/chocolatey-packages/tree/master/automatic/origin</packageSourceUrl>
<owners>AdmiringWorm, thaiphan</owners>
<title>Origin</title>
Expand Down
6 changes: 3 additions & 3 deletions automatic/origin/tools/chocolateyInstall.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ $packageArgs = @{
packageName = $env:ChocolateyPackageName
url = 'https://download.dm.origin.com/origin/live/OriginSetup.exe'
softwareName = 'Origin*' # Probably not needed, but we add registry keys so we keep it
checksum = '87A6AA2D3118B9BB31A768C02B1BE0AC51D8AF9DF95319516C4286C5CE852577F71160FC44F480A6406A47EF067295D4876BC3623AA6F9D2791C8D30924DC991'
checksum = '96CC15D0DAF1DDC3E664AEBD28EC47BC0AC9A4BFCEC83A1CCBCB99438CF2ACE9888DF00F4733119EEA5BEAB79CBB8F5B5F3FE4056614667C997BC1EA2798C100'
checksumType = 'sha512'
destination = Get-PackageCacheLocation
}
Expand All @@ -20,10 +20,10 @@ $packageArgs['file'] = $zipFile
$packageArgs['destination'] = GetInstallLocation $pp

if ($pp.NoAutoUpdate) {
CreateRegistrySettings -installPath $packageArgs['destination'] -autoUpdate $false -version '10.5.8.17910'
CreateRegistrySettings -installPath $packageArgs['destination'] -autoUpdate $false -version '10.5.10.24870'
}
else {
CreateRegistrySettings -installPath $packageArgs['destination'] -autoUpdate $true -version '10.5.8.17910'
CreateRegistrySettings -installPath $packageArgs['destination'] -autoUpdate $true -version '10.5.10.24870'
}

Get-ChocolateyUnzip @packageArgs
Expand Down
8 changes: 4 additions & 4 deletions automatic/origin/tools/helpers.ps1
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
function GetInstallLocation() {
function GetInstallLocation() {
param($pp)

# First check if origin is already installed
$installPath = GetInstallLocationFromRegistry

if ($installPath) { return $installPath }
elseif ($pp.InstallDir) { return $pp.InstallDir }
elseif (Get-ProcessorBits -Compare 32) { return "C:\Program Files\Origin" }
elseif (Get-OSArchitectureWidth -Compare 32) { return "C:\Program Files\Origin" }
else { return "C:\Program Files (x86)\Origin" }
}

Expand Down Expand Up @@ -44,7 +44,7 @@ function CreateRegistrySettings() {
URLInfoAbout = 'http://www.ea.com'
}

if (Get-ProcessorBits -Compare 32) {
if (Get-OSArchitectureWidth -Compare 32) {
$originRegPath = 'HKLM:\SOFTWARE\Origin'
$uninstallRegPath = 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Origin'
}
Expand Down Expand Up @@ -97,7 +97,7 @@ function RemoveShortcuts() {
@(
[System.Environment]::GetFolderPath('CommonPrograms')
[System.Environment]::GetFolderPath('CommonDesktop')
) | % {
) | ForEach-Object {
if (Test-Path "$_\Origin.lnk") { Remove-Item -Force "$_\Origin.lnk" }
}
}

0 comments on commit 7b4c370

Please sign in to comment.