add the ability to override default succeeded() conditioning by parameter (#5780)

Co-authored-by: Scott Beddall <scbedd@microsoft.com>
This commit is contained in:
Azure SDK Bot 2024-07-10 17:26:42 -04:00 коммит произвёл GitHub
Родитель bc547c4f4c
Коммит b1207fc87a
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
4 изменённых файлов: 14 добавлений и 3 удалений

Просмотреть файл

@ -2,6 +2,7 @@
# is used when this pipeline is going to be generating and publishing daily dev builds.
parameters:
ServiceDirectory: ''
Condition: succeeded()
steps:
- ${{if ne(parameters.ServiceDirectory, '')}}:
- task: Powershell@2
@ -13,7 +14,7 @@ steps:
pwsh: true
workingDirectory: $(Pipeline.Workspace)
displayName: Dump Package properties
condition: succeeded()
condition: ${{ parameters.Condition }}
- pwsh: |
$setDailyDevBuild = "false"
if (('$(Build.Reason)' -eq 'Schedule') -and ('$(System.TeamProject)' -eq 'internal')) {
@ -21,4 +22,4 @@ steps:
}
echo "##vso[task.setvariable variable=SetDevVersion]$setDailyDevBuild"
displayName: "Setup Versioning Properties"
condition: and(succeeded(), eq(variables['SetDevVersion'], ''))
condition: and(${{ parameters.Condition }}, eq(variables['SetDevVersion'], ''))

Просмотреть файл

@ -11,6 +11,9 @@ parameters:
- name: ForRelease
type: boolean
default: false
- name: Condition
type: string
default: succeeded()
steps:
- task: Powershell@2
@ -23,4 +26,5 @@ steps:
pwsh: true
workingDirectory: $(Pipeline.Workspace)
displayName: Verify ChangeLogEntry for ${{ parameters.PackageName }}
condition: ${{ parameters.Condition }}
continueOnError: false

Просмотреть файл

@ -1,11 +1,13 @@
# Template for all Python Scripts in this repository
parameters:
parameters:
SourceDirectory: ''
BasePathLength: 49
Condition: succeeded()
steps:
- task: PythonScript@0
displayName: Analyze Path Lengths
condition: ${{ parameters.Condition }}
inputs:
scriptSource: inline
script: |

Просмотреть файл

@ -15,10 +15,14 @@ parameters:
- name: DocWardenVersion
type: string
default: ''
- name: Condition
type: string
default: succeeded()
steps:
- task: PowerShell@2
displayName: "Verify Readmes"
condition: ${{ parameters.Condition }}
inputs:
filePath: "eng/common/scripts/Verify-Readme.ps1"
arguments: >