Last active
August 15, 2022 14:07
-
-
Save dsolovay/85f1ac6b96e0f817242e6fd11bb53ae9 to your computer and use it in GitHub Desktop.
Download Sitecore release notes to hash table
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-SitecoreReleaseNotes() | |
{ | |
$links = (invoke-webrequest https://dev.sitecore.net/Downloads/Sitecore_Experience_Platform.aspx).Links | |
$versions = $links |? {$_.innerText -like 'Sitecore Experience Platform*' -and $_.InnerText -notlike '*and below*'} # https://www.howtogeek.com/124736/stupid-geek-tricks-extract-links-off-any-webpage-using-powershell/ | |
$versionlinks = @{} | |
$versions |% { $versionLinks.Add($_.innerHtml, $_.href)} | |
$releaseNotes = @{} | |
$versionLinks.Keys |%{ | |
$releaseNotesUrl = "https://dev.sitecore.net" + ($versionLinks[$_]).Trim(".aspx") + "/Release%20Notes" | |
Write-Verbose $releaseNotesUrl | |
$releaseNotes.Add($_, ((Invoke-WebRequest -uri $releaseNotesUrl).Content -replace '<[^>]+>','')) # https://stackoverflow.com/a/29930250/402949 | |
write-verbose $releaseNotes[$_] | |
} | |
$releaseNotes | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment