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

[main] Update dependencies from dotnet/arcade #1426

Open
wants to merge 94 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
30da598
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] May 30, 2024
c318a08
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] May 31, 2024
292ca1e
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 1, 2024
2f38435
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 2, 2024
e5ecb23
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 3, 2024
875a701
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 4, 2024
a29f9d8
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 5, 2024
24545e9
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 6, 2024
dde03e3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 7, 2024
3356d17
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 8, 2024
8692db8
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 9, 2024
82763ab
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 10, 2024
bf90613
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 11, 2024
8e3f3ba
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 12, 2024
063433d
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 13, 2024
8653610
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 14, 2024
5a7ea56
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 15, 2024
e61046b
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 16, 2024
ddfc417
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 17, 2024
18603c2
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 18, 2024
dffd979
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 19, 2024
abbe86f
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 20, 2024
528cbd3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 21, 2024
562c4c3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 22, 2024
dcc9250
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 23, 2024
f745961
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 24, 2024
8f42ba9
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 25, 2024
e6fae2b
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 26, 2024
d5c1540
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 27, 2024
046b288
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 28, 2024
74f716a
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 29, 2024
1e8ad47
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jun 30, 2024
f28428e
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 1, 2024
4c5ce31
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 2, 2024
3666de0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 3, 2024
b78c4e0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 4, 2024
63b98d6
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 5, 2024
d1226be
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 6, 2024
5c505bf
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 7, 2024
554bc31
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 8, 2024
809cfc3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 9, 2024
e567674
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 10, 2024
7154225
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 11, 2024
a07b4be
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 12, 2024
8a32a7d
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 13, 2024
9f27095
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 14, 2024
7263f4e
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 15, 2024
0090956
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 16, 2024
5544b61
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 17, 2024
fdb96c3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 18, 2024
cd5f027
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 19, 2024
e6545cf
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 20, 2024
38aedfe
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 21, 2024
5f39af1
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 22, 2024
b84ec48
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 23, 2024
cedea23
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 24, 2024
308999b
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 25, 2024
4d1f8e1
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 26, 2024
4880cb1
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 27, 2024
5cc5a63
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 28, 2024
5892423
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 29, 2024
5876381
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 30, 2024
f5a31ab
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jul 31, 2024
c595fa9
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 1, 2024
7ea53a1
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 2, 2024
44fbb45
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 3, 2024
3fd7ac0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 4, 2024
e34a65c
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 5, 2024
f4fe17e
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 6, 2024
b8e5a7d
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 7, 2024
aa5d71f
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 8, 2024
346fd39
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 9, 2024
e941c8d
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 15, 2024
7fb80be
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 17, 2024
4afb0b7
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 21, 2024
ccb60ee
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 21, 2024
34d3a0f
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 22, 2024
c3ee3d0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 24, 2024
51b05de
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 27, 2024
9f045a3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 29, 2024
73121f0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 30, 2024
7881595
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Aug 31, 2024
e6b8e57
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 6, 2024
eb88c51
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 7, 2024
2452cf5
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 9, 2024
9738464
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 10, 2024
d150a26
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 12, 2024
eec05ff
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 13, 2024
fcca136
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 14, 2024
2c57bd0
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 17, 2024
ae088b8
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 18, 2024
2d334d6
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 24, 2024
a5093b5
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 26, 2024
4f32a7c
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Sep 27, 2024
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="9.0.0-beta.24278.1">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="10.0.0-beta.24476.2">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>0c4e52c37a29b75f64646220e0cc237177ce23a2</Sha>
<Sha>7e8b8f4f321c8671aa01b53567d31aaa4950706f</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
54 changes: 29 additions & 25 deletions eng/common/SetupNugetSources.ps1
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
# 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
# This script adds internal feeds required to build commits that depend on internal package sources. For instance,
# dotnet6-internal would be added automatically if dotnet6 was found in the nuget.config file. In addition also enables
# disabled internal Maestro (darc-int*) feeds.
#
# 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.
# Optionally, this script also adds a credential entry for each of the internal feeds if supplied.
#
# 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.
#
# Any disabledPackageSources entries which start with "darc-int" will be re-enabled as part of this script executing
# See example call for this script below.
#
# - task: PowerShell@2
# displayName: Setup Private Feeds Credentials
Expand All @@ -21,11 +14,18 @@
# arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token
# env:
# Token: $(dn-bot-dnceng-artifact-feeds-rw)
#
# Note that the NuGetAuthenticate task should be called after SetupNugetSources.
# This ensures that:
# - Appropriate creds are set for the added internal feeds (if not supplied to the scrupt)
# - The credential provider is installed.
#
# This logic is also abstracted into enable-internal-sources.yml.

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

$ErrorActionPreference = "Stop"
Expand All @@ -48,11 +48,17 @@ function AddPackageSource($sources, $SourceName, $SourceEndPoint, $creds, $Usern
else {
Write-Host "Package source $SourceName already present."
}

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

# Add a credential node for the specified source
function AddCredential($creds, $source, $username, $pwd) {
# If no cred supplied, don't do anything.
if (!$pwd) {
return;
}

# Looks for credential configuration for the given SourceName. Create it if none is found.
$sourceElement = $creds.SelectSingleNode($Source)
if ($sourceElement -eq $null)
Expand Down Expand Up @@ -110,11 +116,6 @@ if (!(Test-Path $ConfigFile -PathType Leaf)) {
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
Expand All @@ -127,11 +128,14 @@ if ($sources -eq $null) {
$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
$creds = $null
if ($Password) {
# 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
}
}

# Check for disabledPackageSources; we'll enable any darc-int ones we find there
Expand All @@ -153,7 +157,7 @@ if ($dotnet31Source -ne $null) {
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 $userName -pwd $Password
}

$dotnetVersions = @('5','6','7','8')
$dotnetVersions = @('5','6','7','8','9')

foreach ($dotnetVersion in $dotnetVersions) {
$feedPrefix = "dotnet" + $dotnetVersion;
Expand All @@ -164,4 +168,4 @@ foreach ($dotnetVersion in $dotnetVersions) {
}
}

$doc.Save($filename)
$doc.Save($filename)
62 changes: 29 additions & 33 deletions eng/common/SetupNugetSources.sh
Original file line number Diff line number Diff line change
@@ -1,28 +1,27 @@
#!/usr/bin/env bash

# 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
# This script adds internal feeds required to build commits that depend on internal package sources. For instance,
# dotnet6-internal would be added automatically if dotnet6 was found in the nuget.config file. In addition also enables
# disabled internal Maestro (darc-int*) feeds.
#
# Optionally, this script also adds a credential entry for each of the internal feeds if supplied.
#
# 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's 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.
#
# Any disabledPackageSources entries which start with "darc-int" will be re-enabled as part of this script executing.
# See example call for this script below.
#
# - task: Bash@3
# displayName: Setup Private Feeds Credentials
# displayName: Setup Internal Feeds
# inputs:
# filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh
# arguments: $(Build.SourcesDirectory)/NuGet.config $Token
# arguments: $(Build.SourcesDirectory)/NuGet.config
# condition: ne(variables['Agent.OS'], 'Windows_NT')
# env:
# Token: $(dn-bot-dnceng-artifact-feeds-rw)
# - task: NuGetAuthenticate@1
#
# Note that the NuGetAuthenticate task should be called after SetupNugetSources.
# This ensures that:
# - Appropriate creds are set for the added internal feeds (if not supplied to the scrupt)
# - The credential provider is installed.
#
# This logic is also abstracted into enable-internal-sources.yml.

ConfigFile=$1
CredToken=$2
Expand All @@ -48,11 +47,6 @@ if [ ! -f "$ConfigFile" ]; then
ExitWithExitCode 1
fi

if [ -z "$CredToken" ]; then
Write-PipelineTelemetryError -category 'Build' "Error: Eng/common/SetupNugetSources.sh returned a non-zero exit code. Please supply a valid PAT"
ExitWithExitCode 1
fi

if [[ `uname -s` == "Darwin" ]]; then
NL=$'\\\n'
TB=''
Expand Down Expand Up @@ -105,7 +99,7 @@ if [ "$?" == "0" ]; then
PackageSources+=('dotnet3.1-internal-transport')
fi

DotNetVersions=('5' '6' '7' '8')
DotNetVersions=('5' '6' '7' '8' '9')

for DotNetVersion in ${DotNetVersions[@]} ; do
FeedPrefix="dotnet${DotNetVersion}";
Expand Down Expand Up @@ -140,18 +134,20 @@ PackageSources+="$IFS"
PackageSources+=$(grep -oh '"darc-int-[^"]*"' $ConfigFile | tr -d '"')
IFS=$PrevIFS

for FeedName in ${PackageSources[@]} ; do
# Check if there is no existing credential for this FeedName
grep -i "<$FeedName>" $ConfigFile
if [ "$?" != "0" ]; then
echo "Adding credentials for $FeedName."
if [ "$CredToken" ]; then
for FeedName in ${PackageSources[@]} ; do
# Check if there is no existing credential for this FeedName
grep -i "<$FeedName>" $ConfigFile
if [ "$?" != "0" ]; then
echo "Adding credentials for $FeedName."

PackageSourceCredentialsNodeFooter="</packageSourceCredentials>"
NewCredential="${TB}${TB}<$FeedName>${NL}<add key=\"Username\" value=\"dn-bot\" />${NL}<add key=\"ClearTextPassword\" value=\"$CredToken\" />${NL}</$FeedName>"
PackageSourceCredentialsNodeFooter="</packageSourceCredentials>"
NewCredential="${TB}${TB}<$FeedName>${NL}<add key=\"Username\" value=\"dn-bot\" />${NL}<add key=\"ClearTextPassword\" value=\"$CredToken\" />${NL}</$FeedName>"

sed -i.bak "s|$PackageSourceCredentialsNodeFooter|$NewCredential${NL}$PackageSourceCredentialsNodeFooter|" $ConfigFile
fi
done
sed -i.bak "s|$PackageSourceCredentialsNodeFooter|$NewCredential${NL}$PackageSourceCredentialsNodeFooter|" $ConfigFile
fi
done
fi

# Re-enable any entries in disabledPackageSources where the feed name contains darc-int
grep -i "<disabledPackageSources>" $ConfigFile
Expand Down
61 changes: 33 additions & 28 deletions eng/common/core-templates/job/job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,26 +19,21 @@ parameters:
# publishing defaults
artifacts: ''
enableMicrobuild: false
enableMicrobuildForMacAndLinux: false
enablePublishBuildArtifacts: false
enablePublishBuildAssets: false
enablePublishTestResults: false
enablePublishUsingPipelines: false
enableBuildRetry: false
disableComponentGovernance: ''
componentGovernanceIgnoreDirectories: ''
mergeTestResults: false
testRunTitle: ''
testResultsFormat: ''
name: ''
componentGovernanceSteps: []
preSteps: []
artifactPublishSteps: []
runAsPublic: false

# Sbom related params
enableSbom: true
PackageVersion: 9.0.0
BuildDropPath: '$(Build.SourcesDirectory)/artifacts'

# 1es specific parameters
is1ESPipeline: ''

Expand Down Expand Up @@ -140,11 +135,26 @@ jobs:
signType: $(_SignType)
zipSources: false
feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json
${{ if and(eq(parameters.enableMicrobuildForMacAndLinux, 'true'), ne(variables['Agent.Os'], 'Windows_NT')) }}:
azureSubscription: 'MicroBuild Signing Task (DevDiv)'
env:
TeamName: $(_TeamName)
MicroBuildOutputFolderOverride: '$(Agent.TempDirectory)'
SYSTEM_ACCESSTOKEN: $(System.AccessToken)
continueOnError: ${{ parameters.continueOnError }}
condition: and(succeeded(), in(variables['_SignType'], 'real', 'test'), eq(variables['Agent.Os'], 'Windows_NT'))
condition: and(
succeeded(),
or(
and(
eq(variables['Agent.Os'], 'Windows_NT'),
in(variables['_SignType'], 'real', 'test')
),
and(
${{ eq(parameters.enableMicrobuildForMacAndLinux, true) }},
ne(variables['Agent.Os'], 'Windows_NT'),
eq(variables['_SignType'], 'real')
)
))

- ${{ if and(eq(parameters.runAsPublic, 'false'), eq(variables['System.TeamProject'], 'internal')) }}:
- task: NuGetAuthenticate@1
Expand All @@ -170,34 +180,29 @@ jobs:
uploadRichNavArtifacts: ${{ coalesce(parameters.richCodeNavigationUploadArtifacts, false) }}
continueOnError: true

- template: /eng/common/core-templates/steps/component-governance.yml
parameters:
is1ESPipeline: ${{ parameters.is1ESPipeline }}
${{ if eq(parameters.disableComponentGovernance, '') }}:
${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest'), eq(parameters.runAsPublic, 'false'), or(startsWith(variables['Build.SourceBranch'], 'refs/heads/release/'), startsWith(variables['Build.SourceBranch'], 'refs/heads/dotnet/'), startsWith(variables['Build.SourceBranch'], 'refs/heads/microsoft/'), eq(variables['Build.SourceBranch'], 'refs/heads/main'))) }}:
disableComponentGovernance: false
${{ else }}:
disableComponentGovernance: true
${{ else }}:
disableComponentGovernance: ${{ parameters.disableComponentGovernance }}
componentGovernanceIgnoreDirectories: ${{ parameters.componentGovernanceIgnoreDirectories }}
- ${{ each step in parameters.componentGovernanceSteps }}:
- ${{ step }}

- ${{ if eq(parameters.enableMicrobuild, 'true') }}:
- ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}:
- task: MicroBuildCleanup@1
displayName: Execute Microbuild cleanup tasks
condition: and(always(), in(variables['_SignType'], 'real', 'test'), eq(variables['Agent.Os'], 'Windows_NT'))
condition: and(
always(),
or(
and(
eq(variables['Agent.Os'], 'Windows_NT'),
in(variables['_SignType'], 'real', 'test')
),
and(
${{ eq(parameters.enableMicrobuildForMacAndLinux, true) }},
ne(variables['Agent.Os'], 'Windows_NT'),
eq(variables['_SignType'], 'real')
)
))
continueOnError: ${{ parameters.continueOnError }}
env:
TeamName: $(_TeamName)
- ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest'), eq(parameters.enableSbom, 'true')) }}:
- template: /eng/common/core-templates/steps/generate-sbom.yml
parameters:
is1ESPipeline: ${{ parameters.is1ESPipeline }}
PackageVersion: ${{ parameters.packageVersion}}
BuildDropPath: ${{ parameters.buildDropPath }}
IgnoreDirectories: ${{ parameters.componentGovernanceIgnoreDirectories }}
publishArtifacts: false

# Publish test results
- ${{ if or(and(eq(parameters.enablePublishTestResults, 'true'), eq(parameters.testResultsFormat, '')), eq(parameters.testResultsFormat, 'xunit')) }}:
Expand Down
Loading