Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[master] Update dependencies from dotnet/arcade #394

Merged
merged 108 commits into from
Jan 25, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
108 commits
Select commit Hold shift + click to select a range
a956f06
Update dependencies from https://github.com/dotnet/arcade build 20190…
dotnet-maestro[bot] Sep 25, 2019
0760fe9
Update dependencies from https://github.com/dotnet/arcade build 20190…
dotnet-maestro[bot] Sep 27, 2019
8dc3c6d
Update dependencies from https://github.com/dotnet/arcade build 20190…
dotnet-maestro[bot] Sep 28, 2019
0176c70
Update dependencies from https://github.com/dotnet/arcade build 20190…
dotnet-maestro[bot] Oct 1, 2019
c4bd8a1
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 2, 2019
c75fb2e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 3, 2019
7f40f8c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 5, 2019
ab45adb
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 6, 2019
de0e8d6
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 7, 2019
0c2835d
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 10, 2019
8da8ed6
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 11, 2019
e428b84
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 12, 2019
38b7942
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 15, 2019
36f9f93
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 16, 2019
75588fb
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 18, 2019
0cf0d3e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 19, 2019
ae0ef11
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 22, 2019
349206e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 23, 2019
07754f1
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 24, 2019
4b4db17
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 25, 2019
c02d86c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 26, 2019
4a47fcd
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 27, 2019
1c2730e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 28, 2019
ef9b5dd
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 29, 2019
3fef9c5
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 30, 2019
f3b8264
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Oct 31, 2019
0a32740
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 1, 2019
0f1973c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 2, 2019
fb76d74
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 3, 2019
f07e62b
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 5, 2019
3fe5b98
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 6, 2019
3152e50
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 7, 2019
0995130
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 8, 2019
6a667f0
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 9, 2019
e049eaf
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 12, 2019
b70fb51
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 13, 2019
b6b4641
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 14, 2019
0730b19
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 14, 2019
5928186
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 15, 2019
b4dbae8
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 16, 2019
db15bfe
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 17, 2019
b706259
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 18, 2019
fc4d38c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 19, 2019
6405a5e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 20, 2019
8e9dbad
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 21, 2019
0f72df1
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 22, 2019
7d91da8
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 23, 2019
1a00f3f
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 24, 2019
089c0d9
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 25, 2019
f78a595
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 26, 2019
b46707f
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 27, 2019
8b65bad
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 28, 2019
da8b6b1
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 29, 2019
01e2006
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Nov 30, 2019
741f032
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 1, 2019
f091394
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 2, 2019
92714c9
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 3, 2019
792507b
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 4, 2019
e6a4e1e
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 5, 2019
04d8458
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 6, 2019
3e49df3
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 7, 2019
8c90c76
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 8, 2019
68221e3
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 9, 2019
bcbfec2
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 12, 2019
0fa3dae
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 13, 2019
7dc38ba
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 14, 2019
fecb229
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 15, 2019
5e714d8
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 16, 2019
bd09478
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 17, 2019
e70a203
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 18, 2019
d6ad936
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 20, 2019
b44e256
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 21, 2019
4830f8c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 22, 2019
b877675
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 23, 2019
4f620db
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 24, 2019
c3107c8
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 25, 2019
cf15d18
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 26, 2019
d6e2ea2
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 27, 2019
3541538
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 28, 2019
9ae998f
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 29, 2019
d54dc4c
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 30, 2019
8b179fe
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Dec 31, 2019
a0eb520
Update dependencies from https://github.com/dotnet/arcade build 20191…
dotnet-maestro[bot] Jan 1, 2020
dc3d7a5
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 2, 2020
3f57084
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 3, 2020
92b3760
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 4, 2020
d8a80a8
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 5, 2020
ad60c4f
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 6, 2020
a8c339a
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 7, 2020
7856658
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 8, 2020
86f3fb8
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 9, 2020
b7ae69a
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 10, 2020
a52e935
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 11, 2020
284cd6a
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 12, 2020
a97ec0d
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 13, 2020
64050b6
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 15, 2020
1e2526e
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 16, 2020
1ea6bfa
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 17, 2020
fd8f599
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 18, 2020
5448f4c
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 19, 2020
dc9c749
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 22, 2020
4ad4437
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 22, 2020
04cecb8
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 23, 2020
5e74b62
Merge remote-tracking branch 'dotnet/master' into darc-master-9668b52…
sharwell Jan 23, 2020
724e2b3
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 24, 2020
10df0a0
Update dependencies from https://github.com/dotnet/arcade build 20200…
dotnet-maestro[bot] Jan 25, 2020
faf701d
Remove unnecessary workarounds
sharwell Jan 25, 2020
e441426
Implement a workaround for dotnet/wpf#1718
sharwell Jan 25, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<ProductDependencies>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.19470.9">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.20074.6">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>84778cd659cc0509e9ebf651c73f2341ae82df8c</Sha>
<Sha>841c83d8a5b8d8a6bd427f6798b086780138aa9a</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
9 changes: 0 additions & 9 deletions eng/Versions.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>
<PropertyGroup>
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
<!-- This repo version -->
<VersionPrefix>3.2.0</VersionPrefix>
<NugetPackagePrefix>1.0.1</NugetPackagePrefix>
Expand Down Expand Up @@ -58,12 +57,4 @@
<RoslynDiagnosticsAnalyzersVersion>2.6.2-beta2</RoslynDiagnosticsAnalyzersVersion>
<StyleCopAnalyzersVersion>1.2.0-beta.66</StyleCopAnalyzersVersion>
</PropertyGroup>
<PropertyGroup>
<RestoreSources>
$(RestoreSources);
https://dotnet.myget.org/F/roslyn/api/v3/index.json;
https://dotnet.myget.org/F/roslyn-tools/api/v3/index.json;
https://api.nuget.org/v3/index.json
</RestoreSources>
</PropertyGroup>
</Project>
53 changes: 27 additions & 26 deletions eng/common/CheckSymbols.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ param(
)

Add-Type -AssemblyName System.IO.Compression.FileSystem
. $PSScriptRoot\pipeline-logging-functions.ps1

function FirstMatchingSymbolDescriptionOrDefault {
param(
[string] $FullPath, # Full path to the module that has to be checked
[string] $TargetServerParam, # Parameter to pass to `Symbol Tool` indicating the server to lookup for symbols
[string] $TargetServerParameter, # Parameter to pass to `Symbol Tool` indicating the server to lookup for symbols
[string] $SymbolsPath
)

Expand All @@ -21,36 +22,36 @@ function FirstMatchingSymbolDescriptionOrDefault {
# checking and which type of file was uploaded.

# The file itself is returned
$SymbolPath = $SymbolsPath + "\" + $FileName
$SymbolPath = $SymbolsPath + '\' + $FileName

# PDB file for the module
$PdbPath = $SymbolPath.Replace($Extension, ".pdb")
$PdbPath = $SymbolPath.Replace($Extension, '.pdb')

# PDB file for R2R module (created by crossgen)
$NGenPdb = $SymbolPath.Replace($Extension, ".ni.pdb")
$NGenPdb = $SymbolPath.Replace($Extension, '.ni.pdb')

# DBG file for a .so library
$SODbg = $SymbolPath.Replace($Extension, ".so.dbg")
$SODbg = $SymbolPath.Replace($Extension, '.so.dbg')

# DWARF file for a .dylib
$DylibDwarf = $SymbolPath.Replace($Extension, ".dylib.dwarf")
$DylibDwarf = $SymbolPath.Replace($Extension, '.dylib.dwarf')

.\dotnet-symbol.exe --symbols --modules --windows-pdbs $TargetServerParam $FullPath -o $SymbolsPath | Out-Null
.\dotnet-symbol.exe --symbols --modules --windows-pdbs $TargetServerParameter $FullPath -o $SymbolsPath | Out-Null

if (Test-Path $PdbPath) {
return "PDB"
return 'PDB'
}
elseif (Test-Path $NGenPdb) {
return "NGen PDB"
return 'NGen PDB'
}
elseif (Test-Path $SODbg) {
return "DBG for SO"
return 'DBG for SO'
}
elseif (Test-Path $DylibDwarf) {
return "Dwarf for Dylib"
return 'Dwarf for Dylib'
}
elseif (Test-Path $SymbolPath) {
return "Module"
return 'Module'
}
else {
return $null
Expand All @@ -68,15 +69,15 @@ function CountMissingSymbols {
}

# Extensions for which we'll look for symbols
$RelevantExtensions = @(".dll", ".exe", ".so", ".dylib")
$RelevantExtensions = @('.dll', '.exe', '.so', '.dylib')

# How many files are missing symbol information
$MissingSymbols = 0

$PackageId = [System.IO.Path]::GetFileNameWithoutExtension($PackagePath)
$PackageGuid = New-Guid
$ExtractPath = Join-Path -Path $ExtractPath -ChildPath $PackageGuid
$SymbolsPath = Join-Path -Path $ExtractPath -ChildPath "Symbols"
$SymbolsPath = Join-Path -Path $ExtractPath -ChildPath 'Symbols'

[System.IO.Compression.ZipFile]::ExtractToDirectory($PackagePath, $ExtractPath)

Expand All @@ -86,31 +87,31 @@ function CountMissingSymbols {
Get-ChildItem -Recurse $ExtractPath |
Where-Object {$RelevantExtensions -contains $_.Extension} |
ForEach-Object {
if ($_.FullName -Match "\\ref\\") {
if ($_.FullName -Match '\\ref\\') {
Write-Host "`t Ignoring reference assembly file" $_.FullName
return
}

$SymbolsOnMSDL = FirstMatchingSymbolDescriptionOrDefault $_.FullName "--microsoft-symbol-server" $SymbolsPath
$SymbolsOnSymWeb = FirstMatchingSymbolDescriptionOrDefault $_.FullName "--internal-server" $SymbolsPath
$SymbolsOnMSDL = FirstMatchingSymbolDescriptionOrDefault -FullPath $_.FullName -TargetServerParameter '--microsoft-symbol-server' -SymbolsPath $SymbolsPath
$SymbolsOnSymWeb = FirstMatchingSymbolDescriptionOrDefault -FullPath $_.FullName -TargetServerParameter '--internal-server' -SymbolsPath $SymbolsPath

Write-Host -NoNewLine "`t Checking file" $_.FullName "... "

if ($SymbolsOnMSDL -ne $null -and $SymbolsOnSymWeb -ne $null) {
Write-Host "Symbols found on MSDL (" $SymbolsOnMSDL ") and SymWeb (" $SymbolsOnSymWeb ")"
Write-Host "Symbols found on MSDL (${$SymbolsOnMSDL}) and SymWeb (${$SymbolsOnSymWeb})"
}
else {
$MissingSymbols++

if ($SymbolsOnMSDL -eq $null -and $SymbolsOnSymWeb -eq $null) {
Write-Host "No symbols found on MSDL or SymWeb!"
Write-Host 'No symbols found on MSDL or SymWeb!'
}
else {
if ($SymbolsOnMSDL -eq $null) {
Write-Host "No symbols found on MSDL!"
Write-Host 'No symbols found on MSDL!'
}
else {
Write-Host "No symbols found on SymWeb!"
Write-Host 'No symbols found on SymWeb!'
}
}
}
Expand All @@ -129,26 +130,26 @@ function CheckSymbolsAvailable {
Get-ChildItem "$InputPath\*.nupkg" |
ForEach-Object {
$FileName = $_.Name

# These packages from Arcade-Services include some native libraries that
# our current symbol uploader can't handle. Below is a workaround until
# we get issue: https://github.com/dotnet/arcade/issues/2457 sorted.
if ($FileName -Match "Microsoft\.DotNet\.Darc\.") {
if ($FileName -Match 'Microsoft\.DotNet\.Darc\.') {
Write-Host "Ignoring Arcade-services file: $FileName"
Write-Host
return
}
elseif ($FileName -Match "Microsoft\.DotNet\.Maestro\.Tasks\.") {
elseif ($FileName -Match 'Microsoft\.DotNet\.Maestro\.Tasks\.') {
Write-Host "Ignoring Arcade-services file: $FileName"
Write-Host
return
}

Write-Host "Validating $FileName "
$Status = CountMissingSymbols "$InputPath\$FileName"

if ($Status -ne 0) {
Write-Error "Missing symbols for $Status modules in the package $FileName"
Write-PipelineTelemetryError -Category 'CheckSymbols' -Message "Missing symbols for $Status modules in the package $FileName"
}

Write-Host
Expand Down
6 changes: 4 additions & 2 deletions eng/common/PublishToSymbolServers.proj
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
<PropertyGroup>
<DotNetSymbolExpirationInDays Condition="'$(DotNetSymbolExpirationInDays)' == ''">3650</DotNetSymbolExpirationInDays>
<PublishToSymbolServer>true</PublishToSymbolServer>
<PublishToSymWeb Condition="'$(PublishToSymWeb)' == ''">true</PublishToSymWeb>
<PublishToMSDL Condition="'$(PublishToMSDL)' == ''">true</PublishToMSDL>
<PublishToSymbolServer Condition="'@(FilesToPublishToSymbolServer)' == '' and '@(PackagesToPublishToSymbolServer)' == ''">false</PublishToSymbolServer>
</PropertyGroup>

Expand All @@ -56,7 +58,7 @@
DryRun="false"
ConvertPortablePdbsToWindowsPdbs="false"
PdbConversionTreatAsWarning=""
Condition="$(PublishToSymbolServer)"/>
Condition="$(PublishToSymbolServer) and $(PublishToMSDL)"/>

<!--
Symbol Uploader: SymWeb
Expand All @@ -73,7 +75,7 @@
DryRun="false"
ConvertPortablePdbsToWindowsPdbs="false"
PdbConversionTreatAsWarning=""
Condition="$(PublishToSymbolServer)"/>
Condition="$(PublishToSymbolServer) and $(PublishToSymWeb)"/>
</Target>

<ItemGroup>
Expand Down
141 changes: 141 additions & 0 deletions eng/common/SetupNugetSources.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
# This file is a temporary workaround for internal builds to be able to restore from private AzDO feeds.
# This file should be removed as part of this issue: https://github.com/dotnet/arcade/issues/4080
#
# What the script does is iterate over all package sources in the pointed NuGet.config and add a credential entry
# under <packageSourceCredentials> for each Maestro managed private feed. Two additional credential
# entries are also added for the two private static internal feeds: dotnet3-internal and dotnet3-internal-transport.
#
# This script needs to be called in every job that will restore packages and which the base repo has
# private AzDO feeds in the NuGet.config.
#
# See example YAML call for this script below. Note the use of the variable `$(dn-bot-dnceng-artifact-feeds-rw)`
# from the AzureDevOps-Artifact-Feeds-Pats variable group.
#
# - task: PowerShell@2
# displayName: Setup Private Feeds Credentials
# condition: eq(variables['Agent.OS'], 'Windows_NT')
# inputs:
# filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1
# arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token
# env:
# Token: $(dn-bot-dnceng-artifact-feeds-rw)

[CmdletBinding()]
param (
[Parameter(Mandatory = $true)][string]$ConfigFile,
[Parameter(Mandatory = $true)][string]$Password
)

$ErrorActionPreference = "Stop"
Set-StrictMode -Version 2.0
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12

. $PSScriptRoot\tools.ps1

# Add source entry to PackageSources
function AddPackageSource($sources, $SourceName, $SourceEndPoint, $creds, $Username, $Password) {
$packageSource = $sources.SelectSingleNode("add[@key='$SourceName']")

if ($packageSource -eq $null)
{
$packageSource = $doc.CreateElement("add")
$packageSource.SetAttribute("key", $SourceName)
$packageSource.SetAttribute("value", $SourceEndPoint)
$sources.AppendChild($packageSource) | Out-Null
}
else {
Write-Host "Package source $SourceName already present."
}

AddCredential -Creds $creds -Source $SourceName -Username $Username -Password $Password
}

# Add a credential node for the specified source
function AddCredential($creds, $source, $username, $password) {
# Looks for credential configuration for the given SourceName. Create it if none is found.
$sourceElement = $creds.SelectSingleNode($Source)
if ($sourceElement -eq $null)
{
$sourceElement = $doc.CreateElement($Source)
$creds.AppendChild($sourceElement) | Out-Null
}

# Add the <Username> node to the credential if none is found.
$usernameElement = $sourceElement.SelectSingleNode("add[@key='Username']")
if ($usernameElement -eq $null)
{
$usernameElement = $doc.CreateElement("add")
$usernameElement.SetAttribute("key", "Username")
$sourceElement.AppendChild($usernameElement) | Out-Null
}
$usernameElement.SetAttribute("value", $Username)

# Add the <ClearTextPassword> to the credential if none is found.
# Add it as a clear text because there is no support for encrypted ones in non-windows .Net SDKs.
# -> https://github.com/NuGet/Home/issues/5526
$passwordElement = $sourceElement.SelectSingleNode("add[@key='ClearTextPassword']")
if ($passwordElement -eq $null)
{
$passwordElement = $doc.CreateElement("add")
$passwordElement.SetAttribute("key", "ClearTextPassword")
$sourceElement.AppendChild($passwordElement) | Out-Null
}
$passwordElement.SetAttribute("value", $Password)
}

function InsertMaestroPrivateFeedCredentials($Sources, $Creds, $Password) {
$maestroPrivateSources = $Sources.SelectNodes("add[contains(@key,'darc-int')]")

Write-Host "Inserting credentials for $($maestroPrivateSources.Count) Maestro's private feeds."

ForEach ($PackageSource in $maestroPrivateSources) {
Write-Host "`tInserting credential for Maestro's feed:" $PackageSource.Key
AddCredential -Creds $creds -Source $PackageSource.Key -Username $Username -Password $Password
}
}

if (!(Test-Path $ConfigFile -PathType Leaf)) {
Write-PipelineTelemetryError -Category 'Build' -Message "Eng/common/SetupNugetSources.ps1 returned a non-zero exit code. Couldn't find the NuGet config file: $ConfigFile"
ExitWithExitCode 1
}

if (!$Password) {
Write-PipelineTelemetryError -Category 'Build' -Message 'Eng/common/SetupNugetSources.ps1 returned a non-zero exit code. Please supply a valid PAT'
ExitWithExitCode 1
}

# Load NuGet.config
$doc = New-Object System.Xml.XmlDocument
$filename = (Get-Item $ConfigFile).FullName
$doc.Load($filename)

# Get reference to <PackageSources> or create one if none exist already
$sources = $doc.DocumentElement.SelectSingleNode("packageSources")
if ($sources -eq $null) {
$sources = $doc.CreateElement("packageSources")
$doc.DocumentElement.AppendChild($sources) | Out-Null
}

# Looks for a <PackageSourceCredentials> node. Create it if none is found.
$creds = $doc.DocumentElement.SelectSingleNode("packageSourceCredentials")
if ($creds -eq $null) {
$creds = $doc.CreateElement("packageSourceCredentials")
$doc.DocumentElement.AppendChild($creds) | Out-Null
}

# Insert credential nodes for Maestro's private feeds
InsertMaestroPrivateFeedCredentials -Sources $sources -Creds $creds -Password $Password

$dotnet3Source = $sources.SelectSingleNode("add[@key='dotnet3']")
if ($dotnet3Source -ne $null) {
AddPackageSource -Sources $sources -SourceName "dotnet3-internal" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
AddPackageSource -Sources $sources -SourceName "dotnet3-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal-transport/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
}

$dotnet31Source = $sources.SelectSingleNode("add[@key='dotnet3.1']")
if ($dotnet31Source -ne $null) {
AddPackageSource -Sources $sources -SourceName "dotnet3.1-internal" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3.1-internal/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
AddPackageSource -Sources $sources -SourceName "dotnet3.1-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3.1-internal-transport/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
}

$doc.Save($filename)
Loading