Skip to content

Commit

Permalink
Merge pull request #724 from aaronparker/apps
Browse files Browse the repository at this point in the history
Update AdobeAcrobatReaderDC
  • Loading branch information
aaronparker authored Jul 30, 2024
2 parents 0fe3721 + 71bb625 commit edb80e5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
14 changes: 9 additions & 5 deletions Evergreen/Apps/Get-AdobeAcrobatReaderDC.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -22,28 +22,32 @@ Function Get-AdobeAcrobatReaderDC {
#region Installer downloads
foreach ($language in $res.Get.Update.Languages.GetEnumerator()) {

# Get the installer display names for the specified language
Write-Verbose -Message "$($MyInvocation.MyCommand): Searching updates for language: $($language.Name)."
$params = @{
Uri = $res.Get.Update.Uri -replace "#Language", $language.Name
}
$UpdateContent = Invoke-EvergreenRestMethod @params

if ($Null -ne $UpdateContent) {
foreach ($item in $UpdateContent.products.reader) {
if ($null -ne $UpdateContent) {
foreach ($Product in $UpdateContent.products.reader) {

# Search for downloads for each display name returned for the language
$LanguageFullName = $($res.Get.Update.Languages[$language.Key])
Write-Verbose -Message "$($MyInvocation.MyCommand): Searching downloads for language: $LanguageFullName, $($language.Name)."
$params = @{
Uri = $res.Get.Download.Uri -replace "#DisplayName", $item.displayName -replace "#ShortLanguage", $language.Name -replace " ", "%20"
Uri = $res.Get.Download.Uri -replace "#DisplayName", $Product.displayName -replace "#ShortLanguage", $language.Name -replace " ", "%20"
}
$DownloadContent = Invoke-EvergreenRestMethod @params

# Build the output object
if ($null -ne $DownloadContent) {
$PSObject = [PSCustomObject] @{
Version = $item.version
Version = $Product.version
Language = $LanguageFullName
Size = [System.Int32]$Product.fileSize
Architecture = Get-Architecture -String $DownloadContent.downloadURL
Name = $item.displayName
#Name = $Product.displayName
URI = $DownloadContent.downloadURL
}
Write-Output -InputObject $PSObject
Expand Down
3 changes: 2 additions & 1 deletion Evergreen/Manifests/AdobeAcrobatReaderDC.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
"Source": "https://acrobat.adobe.com/us/en/acrobat/pdf-reader.html",
"Get": {
"Update": {
"Uri": "https://rdc.adobe.io/reader/products?lang=#Language&site=enterprise&os=Windows%2011&api_key=dc-get-adobereader-cdn",
"Uri2": "https://rdc.adobe.io/reader/products?lang=#Language&site=enterprise&os=Windows%2011&api_key=dc-get-adobereader-cdn",
"Uri": "https://rdc.adobe.io/reader/products?lang=#Language&site=otherversions&os=Windows%2010&preInstalled=&api_key=dc-get-adobereader-cdn",
"Languages": {
"mui": "MUI",
"en": "English",
Expand Down

0 comments on commit edb80e5

Please sign in to comment.