From 05b6a7913940e1de94e06de26c6071c01d08cd8f Mon Sep 17 00:00:00 2001 From: Patrick Hallisey Date: Tue, 9 Jul 2024 14:37:58 -0700 Subject: [PATCH 1/2] Use eng/common template for create-tags-and-git-release --- eng/pipelines/templates/jobs/mgmt-release.yml | 22 ++++++------------- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/eng/pipelines/templates/jobs/mgmt-release.yml b/eng/pipelines/templates/jobs/mgmt-release.yml index 180d914069fb7..f73666dea23d9 100644 --- a/eng/pipelines/templates/jobs/mgmt-release.yml +++ b/eng/pipelines/templates/jobs/mgmt-release.yml @@ -39,21 +39,13 @@ jobs: - ${{ if and(eq(parameters.ShouldPublishToNuget, 'true'), eq(variables['Build.Repository.Name'], 'Azure/azure-sdk-for-net')) }}: - - task: Powershell@2 - displayName: 'Verify Package Tags and Create Git Releases' - inputs: - filePath: ${{ parameters.BuildToolsPath }}/scripts/create-tags-and-git-release.ps1 - arguments: > - -artifactLocation '$(PIPELINE.WORKSPACE)/packages' - -workingDirectory $(System.DefaultWorkingDirectory) - -packageRepository 'Nuget' - -releaseSha '$(Build.SourceVersion)' - -repoOwner 'Azure' - -repoName 'azure-sdk-for-net' - pwsh: true - env: - GH_TOKEN: $(azuresdk-github-pat) - condition: and(succeeded(), ne(variables['SkipCreateTagAndGitRelease'], 'true')) + - template: /eng/common/pipelines/templates/steps/create-tags-and-git-release.yml + parameters: + ArtifactLocation: '$(PIPELINE.WORKSPACE)/packages' + WorkingDirectory: $(System.DefaultWorkingDirectory) + PackageRepository: Nuget + ReleaseSha: $(Build.SourceVersion) + RepoId: Azure/azure-sdk-for-net - template: pipelines/steps/publish-symbols.yml@azure-sdk-build-tools displayName: 'Upload Symbols' From 93a2cf4b6ff25eb963dbb9bcda9218365d3d3d75 Mon Sep 17 00:00:00 2001 From: Patrick Hallisey Date: Tue, 9 Jul 2024 15:43:03 -0700 Subject: [PATCH 2/2] Remove unnecessary parameters --- eng/pipelines/templates/jobs/mgmt-release.yml | 2 -- eng/pipelines/templates/stages/archetype-net-release.yml | 1 - 2 files changed, 3 deletions(-) diff --git a/eng/pipelines/templates/jobs/mgmt-release.yml b/eng/pipelines/templates/jobs/mgmt-release.yml index f73666dea23d9..6fa22b788584d 100644 --- a/eng/pipelines/templates/jobs/mgmt-release.yml +++ b/eng/pipelines/templates/jobs/mgmt-release.yml @@ -42,10 +42,8 @@ jobs: - template: /eng/common/pipelines/templates/steps/create-tags-and-git-release.yml parameters: ArtifactLocation: '$(PIPELINE.WORKSPACE)/packages' - WorkingDirectory: $(System.DefaultWorkingDirectory) PackageRepository: Nuget ReleaseSha: $(Build.SourceVersion) - RepoId: Azure/azure-sdk-for-net - template: pipelines/steps/publish-symbols.yml@azure-sdk-build-tools displayName: 'Upload Symbols' diff --git a/eng/pipelines/templates/stages/archetype-net-release.yml b/eng/pipelines/templates/stages/archetype-net-release.yml index 7be7e0de1634c..4465fb157c0ef 100644 --- a/eng/pipelines/templates/stages/archetype-net-release.yml +++ b/eng/pipelines/templates/stages/archetype-net-release.yml @@ -105,7 +105,6 @@ stages: ArtifactLocation: $(Pipeline.Workspace)/${{parameters.ArtifactName}}-signed/${{artifact.name}} PackageRepository: Nuget ReleaseSha: $(Build.SourceVersion) - RepoId: Azure/azure-sdk-for-net - ${{if ne(artifact.skipPublishPackage, 'true')}}: - deployment: PublishPackage