mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-13 13:26:48 +00:00
[Windows] Install vsix extensions using CDN endpoint (#3244)
* Install extensions for VS19 * Get vsix packages name in runtime * add a bit of debug * Get extension id from the marketplace uri * Add extension name * skip vcredist installation * Add Get-VsixExtenstionFromMarketplace to ImageHelpers.psm1 * Fix DownloadUri name in the function * DownloadUri in lower case * Add packages to the readme * Add a condition to software report * fix spelling in function * Simplify toolset + get rid of backticks
This commit is contained in:
@@ -20,6 +20,21 @@ function Get-WDKVersion {
|
||||
}
|
||||
|
||||
function Get-VisualStudioExtensions {
|
||||
# Additional vsixs
|
||||
$toolset = Get-ToolsetContent
|
||||
$vsixUrls = $toolset.visualStudio.vsix
|
||||
if ($vsixUrls)
|
||||
{
|
||||
$vsixs = $vsixUrls | ForEach-Object {
|
||||
$vsix = Get-VsixExtenstionFromMarketplace -ExtensionMarketPlaceName $_
|
||||
$vsixVersion = (Get-VisualStudioPackages | Where-Object {$_.Id -match $vsix.VsixId -and $_.type -eq 'vsix'}).Version
|
||||
@{
|
||||
Package = $vsix.ExtensionName
|
||||
Version = $vsixVersion
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Wix
|
||||
$vs = (Get-VisualStudioVersion).Name.Split()[-1]
|
||||
$wixPackageVersion = Get-WixVersion
|
||||
@@ -29,18 +44,9 @@ function Get-VisualStudioExtensions {
|
||||
$wdkPackageVersion = Get-VSExtensionVersion -packageName 'Microsoft.Windows.DriverKit'
|
||||
$wdkExtensionVersion = Get-WDKVersion
|
||||
|
||||
# SSDT
|
||||
$analysisPackageVersion = Get-VSExtensionVersion -packageName '04a86fc2-dbd5-4222-848e-911638e487fe'
|
||||
$reportingPackageVersion = Get-VSExtensionVersion -packageName '717ad572-c4b7-435c-c166-c2969777f718'
|
||||
|
||||
$integrationPackageName = ($vs -match "2019") ? '851E7A09-7B2B-4F06-A15D-BABFCB26B970' : 'D1B09713-C12E-43CC-9EF4-6562298285AB'
|
||||
$integrationPackageVersion = Get-VSExtensionVersion -packageName $integrationPackageName
|
||||
|
||||
$extensions = @(
|
||||
@{Package = 'SSDT Microsoft Analysis Services Projects'; Version = $analysisPackageVersion}
|
||||
@{Package = 'SSDT SQL Server Integration Services Projects'; Version = $integrationPackageVersion}
|
||||
@{Package = 'SSDT Microsoft Reporting Services Projects'; Version = $reportingPackageVersion}
|
||||
@{Package = 'Windows Driver Kit'; Version = $wixPackageVersion}
|
||||
$vsixs
|
||||
@{Package = 'Windows Driver Kit'; Version = $wdkPackageVersion}
|
||||
@{Package = 'Windows Driver Kit Visual Studio Extension'; Version = $wdkExtensionVersion}
|
||||
@{Package = 'WIX Toolset'; Version = $wixPackageVersion}
|
||||
@{Package = "WIX Toolset Studio $vs Extension"; Version = $wixExtensionVersion}
|
||||
@@ -48,5 +54,5 @@ function Get-VisualStudioExtensions {
|
||||
|
||||
$extensions | Foreach-Object {
|
||||
[PSCustomObject]$_
|
||||
} | Select-Object Package, Version
|
||||
} | Select-Object Package, Version | Sort-Object Package
|
||||
}
|
||||
Reference in New Issue
Block a user