Skip to content

Commit 0f05564

Browse files
Merged PR 54333: internal/release/8.0.4xx - merge from public
2 parents aef60c9 + 411a711 commit 0f05564

File tree

20 files changed

+202
-38
lines changed

20 files changed

+202
-38
lines changed

NuGet.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
<add key="darc-int-dotnet-runtime-f8f07a0" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-f8f07a0a/nuget/v3/index.json" />
2626
<!-- End: Package sources from dotnet-runtime -->
2727
<!-- Begin: Package sources from dotnet-templating -->
28-
<add key="darc-pub-dotnet-templating-a2c4545" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-templating-a2c45457/nuget/v3/index.json" />
28+
<add key="darc-pub-dotnet-templating-fe0130d" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-templating-fe0130d7/nuget/v3/index.json" />
2929
<!-- End: Package sources from dotnet-templating -->
3030
<!-- Begin: Package sources from dotnet-windowsdesktop -->
3131
<add key="darc-int-dotnet-windowsdesktop-9df853f" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-windowsdesktop-9df853fd/nuget/v3/index.json" />

eng/Version.Details.xml

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
<ProductDependencies>
44
<Dependency Name="Microsoft.TemplateEngine.Abstractions" Version="8.0.415">
55
<Uri>https://github.com/dotnet/templating</Uri>
6-
<Sha>a2c45457884ceb15ab6e368c87571ce1e480fc93</Sha>
6+
<Sha>fe0130d773314a195b81fb2eecfb14db9b847563</Sha>
77
</Dependency>
8-
<Dependency Name="Microsoft.TemplateEngine.Mocks" Version="8.0.415-servicing.25457.4">
8+
<Dependency Name="Microsoft.TemplateEngine.Mocks" Version="8.0.415-servicing.25465.9">
99
<Uri>https://github.com/dotnet/templating</Uri>
10-
<Sha>a2c45457884ceb15ab6e368c87571ce1e480fc93</Sha>
10+
<Sha>fe0130d773314a195b81fb2eecfb14db9b847563</Sha>
1111
</Dependency>
12-
<Dependency Name="Microsoft.SourceBuild.Intermediate.templating" Version="8.0.415-servicing.25457.4">
12+
<Dependency Name="Microsoft.SourceBuild.Intermediate.templating" Version="8.0.415-servicing.25465.9">
1313
<Uri>https://github.com/dotnet/templating</Uri>
14-
<Sha>a2c45457884ceb15ab6e368c87571ce1e480fc93</Sha>
14+
<Sha>fe0130d773314a195b81fb2eecfb14db9b847563</Sha>
1515
<SourceBuild RepoName="templating" ManagedOnly="true" />
1616
</Dependency>
1717
<Dependency Name="Microsoft.NETCore.App.Ref" Version="8.0.22">
@@ -354,9 +354,9 @@
354354
<Sha>16bcad1c13be082bd52ce178896d1119a73081a9</Sha>
355355
<SourceBuild RepoName="source-build-externals" ManagedOnly="true" />
356356
</Dependency>
357-
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-reference-packages" Version="8.0.0-alpha.1.25428.6">
357+
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-reference-packages" Version="8.0.0-alpha.1.25507.1">
358358
<Uri>https://github.com/dotnet/source-build-reference-packages</Uri>
359-
<Sha>0b4984f8ee945e02a39ef0f72dc9f7ceab65c14f</Sha>
359+
<Sha>7a3266db9e2b7422e8277f04932eff9b7064b66e</Sha>
360360
<SourceBuild RepoName="source-build-reference-packages" ManagedOnly="true" />
361361
</Dependency>
362362
<Dependency Name="Microsoft.Deployment.DotNet.Releases" Version="2.0.0-rtm.1.25064.1">
@@ -491,22 +491,22 @@
491491
</Dependency>
492492
</ProductDependencies>
493493
<ToolsetDependencies>
494-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.25415.2">
494+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.25504.1">
495495
<Uri>https://github.com/dotnet/arcade</Uri>
496-
<Sha>2f70e458e03e348a3a1f3fd6b9b70b4fcd5ba596</Sha>
496+
<Sha>3edea53c9b10e4bc63de863d71a05d47d9bb5b69</Sha>
497497
<SourceBuild RepoName="arcade" ManagedOnly="true" />
498498
</Dependency>
499-
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.25415.2">
499+
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.25504.1">
500500
<Uri>https://github.com/dotnet/arcade</Uri>
501-
<Sha>2f70e458e03e348a3a1f3fd6b9b70b4fcd5ba596</Sha>
501+
<Sha>3edea53c9b10e4bc63de863d71a05d47d9bb5b69</Sha>
502502
</Dependency>
503-
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.25415.2">
503+
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.25504.1">
504504
<Uri>https://github.com/dotnet/arcade</Uri>
505-
<Sha>2f70e458e03e348a3a1f3fd6b9b70b4fcd5ba596</Sha>
505+
<Sha>3edea53c9b10e4bc63de863d71a05d47d9bb5b69</Sha>
506506
</Dependency>
507-
<Dependency Name="Microsoft.DotNet.XUnitExtensions" Version="8.0.0-beta.25415.2">
507+
<Dependency Name="Microsoft.DotNet.XUnitExtensions" Version="8.0.0-beta.25504.1">
508508
<Uri>https://github.com/dotnet/arcade</Uri>
509-
<Sha>2f70e458e03e348a3a1f3fd6b9b70b4fcd5ba596</Sha>
509+
<Sha>3edea53c9b10e4bc63de863d71a05d47d9bb5b69</Sha>
510510
</Dependency>
511511
<Dependency Name="System.Reflection.MetadataLoadContext" Version="8.0.1">
512512
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>

eng/Versions.props

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
<SystemCollectionsImmutablePackageVersion>8.0.0</SystemCollectionsImmutablePackageVersion>
3737
<SystemDiagnosticsFileVersionInfoVersion>4.0.0</SystemDiagnosticsFileVersionInfoVersion>
3838
<SystemReflectionMetadataVersion>8.0.0</SystemReflectionMetadataVersion>
39-
<MicrosoftDotNetSignToolVersion>8.0.0-beta.25415.2</MicrosoftDotNetSignToolVersion>
39+
<MicrosoftDotNetSignToolVersion>8.0.0-beta.25504.1</MicrosoftDotNetSignToolVersion>
4040
<MicrosoftWebXdtPackageVersion>7.0.0-preview.22423.2</MicrosoftWebXdtPackageVersion>
4141
<SystemSecurityCryptographyProtectedDataPackageVersion>8.0.0</SystemSecurityCryptographyProtectedDataPackageVersion>
4242
<SystemCollectionsSpecializedPackageVersion>4.3.0</SystemCollectionsSpecializedPackageVersion>
@@ -149,7 +149,7 @@
149149
<MicrosoftTemplateEngineUtilsPackageVersion>$(MicrosoftTemplateEngineAbstractionsPackageVersion)</MicrosoftTemplateEngineUtilsPackageVersion>
150150
<MicrosoftTemplateSearchCommonPackageVersion>$(MicrosoftTemplateEngineAbstractionsPackageVersion)</MicrosoftTemplateSearchCommonPackageVersion>
151151
<!-- test dependencies -->
152-
<MicrosoftTemplateEngineMocksPackageVersion>8.0.415-servicing.25457.4</MicrosoftTemplateEngineMocksPackageVersion>
152+
<MicrosoftTemplateEngineMocksPackageVersion>8.0.415-servicing.25465.9</MicrosoftTemplateEngineMocksPackageVersion>
153153
<MicrosoftTemplateEngineTestHelperPackageVersion>$(MicrosoftTemplateEngineMocksPackageVersion)</MicrosoftTemplateEngineTestHelperPackageVersion>
154154
<MicrosoftTemplateEngineAuthoringTemplateVerifierVersion>$(MicrosoftTemplateEngineAbstractionsPackageVersion)</MicrosoftTemplateEngineAuthoringTemplateVerifierVersion>
155155
<MicrosoftTemplateSearchTemplateDiscoveryPackageVersion>$(MicrosoftTemplateEngineMocksPackageVersion)</MicrosoftTemplateSearchTemplateDiscoveryPackageVersion>
@@ -215,7 +215,7 @@
215215
<PropertyGroup>
216216
<FluentAssertionsVersion>6.12.0</FluentAssertionsVersion>
217217
<FluentAssertionsJsonVersion>6.1.0</FluentAssertionsJsonVersion>
218-
<MicrosoftDotNetXUnitExtensionsVersion>8.0.0-beta.25415.2</MicrosoftDotNetXUnitExtensionsVersion>
218+
<MicrosoftDotNetXUnitExtensionsVersion>8.0.0-beta.25504.1</MicrosoftDotNetXUnitExtensionsVersion>
219219
<MoqPackageVersion>4.18.4</MoqPackageVersion>
220220
<XunitCombinatorialVersion>1.3.2</XunitCombinatorialVersion>
221221
<MicrosoftDotNetInstallerWindowsSecurityTestDataPackageVersion>8.0.0-beta.23607.1</MicrosoftDotNetInstallerWindowsSecurityTestDataPackageVersion>

eng/common/post-build/nuget-validation.ps1

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,13 @@
22
# tool: https://github.com/NuGet/NuGetGallery/tree/jver-verify/src/VerifyMicrosoftPackage
33

44
param(
5-
[Parameter(Mandatory=$true)][string] $PackagesPath, # Path to where the packages to be validated are
6-
[Parameter(Mandatory=$true)][string] $ToolDestinationPath # Where the validation tool should be downloaded to
5+
[Parameter(Mandatory=$true)][string] $PackagesPath # Path to where the packages to be validated are
76
)
87

98
try {
109
. $PSScriptRoot\post-build-utils.ps1
1110

12-
$url = 'https://raw.githubusercontent.com/NuGet/NuGetGallery/3e25ad135146676bcab0050a516939d9958bfa5d/src/VerifyMicrosoftPackage/verify.ps1'
13-
14-
New-Item -ItemType 'directory' -Path ${ToolDestinationPath} -Force
15-
16-
Invoke-WebRequest $url -OutFile ${ToolDestinationPath}\verify.ps1
17-
18-
& ${ToolDestinationPath}\verify.ps1 ${PackagesPath}\*.nupkg
11+
& $PSScriptRoot\nuget-verification.ps1 ${PackagesPath}\*.nupkg
1912
}
2013
catch {
2114
Write-Host $_.ScriptStackTrace
Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
<#
2+
.SYNOPSIS
3+
Verifies that Microsoft NuGet packages have proper metadata.
4+
.DESCRIPTION
5+
Downloads a verification tool and runs metadata validation on the provided NuGet packages. This script writes an
6+
error if any of the provided packages fail validation. All arguments provided to this PowerShell script that do not
7+
match PowerShell parameters are passed on to the verification tool downloaded during the execution of this script.
8+
.PARAMETER NuGetExePath
9+
The path to the nuget.exe binary to use. If not provided, nuget.exe will be downloaded into the -DownloadPath
10+
directory.
11+
.PARAMETER PackageSource
12+
The package source to use to download the verification tool. If not provided, nuget.org will be used.
13+
.PARAMETER DownloadPath
14+
The directory path to download the verification tool and nuget.exe to. If not provided,
15+
%TEMP%\NuGet.VerifyNuGetPackage will be used.
16+
.PARAMETER args
17+
Arguments that will be passed to the verification tool.
18+
.EXAMPLE
19+
PS> .\verify.ps1 *.nupkg
20+
Verifies the metadata of all .nupkg files in the currect working directory.
21+
.EXAMPLE
22+
PS> .\verify.ps1 --help
23+
Displays the help text of the downloaded verifiction tool.
24+
.LINK
25+
https://github.com/NuGet/NuGetGallery/blob/master/src/VerifyMicrosoftPackage/README.md
26+
#>
27+
28+
# This script was copied from https://github.com/NuGet/NuGetGallery/blob/3e25ad135146676bcab0050a516939d9958bfa5d/src/VerifyMicrosoftPackage/verify.ps1
29+
30+
[CmdletBinding(PositionalBinding = $false)]
31+
param(
32+
[string]$NuGetExePath,
33+
[string]$PackageSource = "https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-public/nuget/v3/index.json",
34+
[string]$DownloadPath,
35+
[Parameter(ValueFromRemainingArguments = $true)]
36+
[string[]]$args
37+
)
38+
39+
# The URL to download nuget.exe.
40+
$nugetExeUrl = "https://dist.nuget.org/win-x86-commandline/v4.9.4/nuget.exe"
41+
42+
# The package ID of the verification tool.
43+
$packageId = "NuGet.VerifyMicrosoftPackage"
44+
45+
# The location that nuget.exe and the verification tool will be downloaded to.
46+
if (!$DownloadPath) {
47+
$DownloadPath = (Join-Path $env:TEMP "NuGet.VerifyMicrosoftPackage")
48+
}
49+
50+
$fence = New-Object -TypeName string -ArgumentList '=', 80
51+
52+
# Create the download directory, if it doesn't already exist.
53+
if (!(Test-Path $DownloadPath)) {
54+
New-Item -ItemType Directory $DownloadPath | Out-Null
55+
}
56+
Write-Host "Using download path: $DownloadPath"
57+
58+
if ($NuGetExePath) {
59+
$nuget = $NuGetExePath
60+
} else {
61+
$downloadedNuGetExe = Join-Path $DownloadPath "nuget.exe"
62+
63+
# Download nuget.exe, if it doesn't already exist.
64+
if (!(Test-Path $downloadedNuGetExe)) {
65+
Write-Host "Downloading nuget.exe from $nugetExeUrl..."
66+
$ProgressPreference = 'SilentlyContinue'
67+
try {
68+
Invoke-WebRequest $nugetExeUrl -OutFile $downloadedNuGetExe
69+
$ProgressPreference = 'Continue'
70+
} catch {
71+
$ProgressPreference = 'Continue'
72+
Write-Error $_
73+
Write-Error "nuget.exe failed to download."
74+
exit
75+
}
76+
}
77+
78+
$nuget = $downloadedNuGetExe
79+
}
80+
81+
Write-Host "Using nuget.exe path: $nuget"
82+
Write-Host " "
83+
84+
# Download the latest version of the verification tool.
85+
Write-Host "Downloading the latest version of $packageId from $packageSource..."
86+
Write-Host $fence
87+
& $nuget install $packageId `
88+
-Prerelease `
89+
-OutputDirectory $DownloadPath `
90+
-Source $PackageSource
91+
Write-Host $fence
92+
Write-Host " "
93+
94+
if ($LASTEXITCODE -ne 0) {
95+
Write-Error "nuget.exe failed to fetch the verify tool."
96+
exit
97+
}
98+
99+
# Find the most recently downloaded tool
100+
Write-Host "Finding the most recently downloaded verification tool."
101+
$verifyProbePath = Join-Path $DownloadPath "$packageId.*"
102+
$verifyPath = Get-ChildItem -Path $verifyProbePath -Directory `
103+
| Sort-Object -Property LastWriteTime -Descending `
104+
| Select-Object -First 1
105+
$verify = Join-Path $verifyPath "tools\NuGet.VerifyMicrosoftPackage.exe"
106+
Write-Host "Using verification tool: $verify"
107+
Write-Host " "
108+
109+
# Execute the verification tool.
110+
Write-Host "Executing the verify tool..."
111+
Write-Host $fence
112+
& $verify $args
113+
Write-Host $fence
114+
Write-Host " "
115+
116+
# Respond to the exit code.
117+
if ($LASTEXITCODE -ne 0) {
118+
Write-Error "The verify tool found some problems."
119+
} else {
120+
Write-Output "The verify tool succeeded."
121+
}

eng/common/templates-official/job/publish-build-assets.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ parameters:
3232

3333
repositoryAlias: self
3434

35+
officialBuildId: ''
36+
3537
jobs:
3638
- job: Asset_Registry_Publish
3739

@@ -52,6 +54,11 @@ jobs:
5254
value: false
5355
- ${{ if eq(parameters.publishAssetsImmediately, 'true') }}:
5456
- template: /eng/common/templates-official/post-build/common-variables.yml
57+
- name: OfficialBuildId
58+
${{ if ne(parameters.officialBuildId, '') }}:
59+
value: ${{ parameters.officialBuildId }}
60+
${{ else }}:
61+
value: $(Build.BuildNumber)
5562

5663
pool:
5764
# We don't use the collection uri here because it might vary (.visualstudio.com vs. dev.azure.com)
@@ -93,7 +100,7 @@ jobs:
93100
/p:ManifestsPath='$(Build.StagingDirectory)/Download/AssetManifests'
94101
/p:MaestroApiEndpoint=https://maestro.dot.net
95102
/p:PublishUsingPipelines=${{ parameters.publishUsingPipelines }}
96-
/p:OfficialBuildId=$(Build.BuildNumber)
103+
/p:OfficialBuildId=$(OfficialBuildId)
97104
condition: ${{ parameters.condition }}
98105
continueOnError: ${{ parameters.continueOnError }}
99106

eng/common/templates-official/job/source-build.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ parameters:
3131
# container and pool.
3232
platform: {}
3333

34+
# Optional list of directories to ignore for component governance scans.
35+
cgIgnoreDirectories: []
36+
3437
# If set to true and running on a non-public project,
3538
# Internal blob storage locations will be enabled.
3639
# This is not enabled by default because many repositories do not need internal sources
@@ -73,3 +76,4 @@ jobs:
7376
- template: /eng/common/templates-official/steps/source-build.yml
7477
parameters:
7578
platform: ${{ parameters.platform }}
79+
cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }}

eng/common/templates-official/jobs/jobs.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ parameters:
4141
enableSourceIndex: false
4242
sourceIndexParams: {}
4343
repositoryAlias: self
44+
officialBuildId: ''
4445

4546
# Internal resources (telemetry, microbuild) can only be accessed from non-public projects,
4647
# and some (Microbuild) should only be applied to non-PR cases for internal builds.
@@ -97,3 +98,4 @@ jobs:
9798
artifactsPublishingAdditionalParameters: ${{ parameters.artifactsPublishingAdditionalParameters }}
9899
signingValidationAdditionalParameters: ${{ parameters.signingValidationAdditionalParameters }}
99100
repositoryAlias: ${{ parameters.repositoryAlias }}
101+
officialBuildId: ${{ parameters.officialBuildId }}

eng/common/templates-official/jobs/source-build.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ parameters:
2121
# one job runs on 'defaultManagedPlatform'.
2222
platforms: []
2323

24+
# Optional list of directories to ignore for component governance scans.
25+
cgIgnoreDirectories: []
26+
2427
# If set to true and running on a non-public project,
2528
# Internal nuget and blob storage locations will be enabled.
2629
# This is not enabled by default because many repositories do not need internal sources
@@ -44,11 +47,13 @@ jobs:
4447
parameters:
4548
jobNamePrefix: ${{ parameters.jobNamePrefix }}
4649
platform: ${{ platform }}
50+
cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }}
4751
enableInternalSources: ${{ parameters.enableInternalSources }}
4852

4953
- ${{ if eq(length(parameters.platforms), 0) }}:
5054
- template: /eng/common/templates-official/job/source-build.yml
5155
parameters:
5256
jobNamePrefix: ${{ parameters.jobNamePrefix }}
5357
platform: ${{ parameters.defaultManagedPlatform }}
58+
cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }}
5459
enableInternalSources: ${{ parameters.enableInternalSources }}

eng/common/templates-official/post-build/post-build.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,7 @@ stages:
134134
displayName: Validate
135135
inputs:
136136
filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/nuget-validation.ps1
137-
arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/
138-
-ToolDestinationPath $(Agent.BuildDirectory)/Extract/
137+
arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/
139138

140139
- job:
141140
displayName: Signing Validation

0 commit comments

Comments
 (0)