|
| 1 | +# This is a simple wrapper for eng/pipeline.yml to get around the limitation of |
| 2 | +# user-defined variables not being available in yaml template expressions. |
| 3 | + |
| 4 | +# Parameters ARE available in template expressions, and parameters can have default values, |
| 5 | +# so they can be used to control yaml flow. |
| 6 | +# |
| 7 | + |
| 8 | +variables: |
| 9 | + # clean the local repo on the build agents |
| 10 | + - name: Build.Repository.Clean |
| 11 | + value: true |
| 12 | + - name: _DotNetArtifactsCategory |
| 13 | + value: WINDOWSDESKTOP |
| 14 | + - name: _DotNetValidationArtifactsCategory |
| 15 | + value: WINDOWSDESKTOP |
| 16 | + - ${{ if or(startswith(variables['Build.SourceBranch'], 'refs/heads/release/'), startswith(variables['Build.SourceBranch'], 'refs/heads/internal/release/'), eq(variables['Build.Reason'], 'Manual')) }}: |
| 17 | + - name: PostBuildSign |
| 18 | + value: false |
| 19 | + - ${{ else }}: |
| 20 | + - name: PostBuildSign |
| 21 | + value: true |
| 22 | + |
| 23 | + - ${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: |
| 24 | + - group: DotNet-Wpf-SDLValidation-Params |
| 25 | + |
| 26 | + |
| 27 | +# This is set in the pipeline directly |
| 28 | +# When set to false, CI tests will not be enabled in builds. |
| 29 | +# |
| 30 | +# _ContinuousIntegrationTestsEnabled: false |
| 31 | + |
| 32 | +# Setting batch to true, triggers one build at a time. |
| 33 | +# if there is a push while a build in progress, it will wait, |
| 34 | +# until the running build finishes, and produce a build with all the changes |
| 35 | +# |
| 36 | +# only trigger ci builds for the master and release branches |
| 37 | +trigger: |
| 38 | + batch: true |
| 39 | + branches: |
| 40 | + include: |
| 41 | + - main |
| 42 | + - release/* |
| 43 | + - internal/release/* |
| 44 | + - experimental/* |
| 45 | + paths: |
| 46 | + exclude: |
| 47 | + - Documentation/* |
| 48 | + |
| 49 | +pr: |
| 50 | + autoCancel: true |
| 51 | + branches: |
| 52 | + include: |
| 53 | + - main |
| 54 | + - release/* |
| 55 | + - experimental/* |
| 56 | + - feature/win11theming/staging |
| 57 | + - feature/win11theming/release |
| 58 | + paths: |
| 59 | + exclude: |
| 60 | + - Documentation/* |
| 61 | + |
| 62 | +# Call the pipeline.yml template, which does the real work |
| 63 | +stages: |
| 64 | +- stage: build |
| 65 | + displayName: Build |
| 66 | + jobs: |
| 67 | + - template: /eng/pipeline.yml |
| 68 | + parameters: |
| 69 | + ${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: |
| 70 | + runAsPublic: false |
| 71 | + |
| 72 | +- ${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: |
| 73 | + - template: eng\common\templates\post-build\post-build.yml |
| 74 | + parameters: |
| 75 | + publishingInfraVersion: 3 |
| 76 | + enableSymbolValidation: false |
| 77 | + enableSigningValidation: false |
| 78 | + enableNugetValidation: false |
| 79 | + enableSourceLinkValidation: false |
| 80 | + # This is to enable SDL runs part of Post-Build Validation Stage |
| 81 | + SDLValidationParameters: |
| 82 | + enable: false |
| 83 | + params: ' -SourceToolsList @("policheck","credscan") |
| 84 | + -TsaInstanceURL $(_TsaInstanceURL) |
| 85 | + -TsaProjectName $(_TsaProjectName) |
| 86 | + -TsaNotificationEmail $(_TsaNotificationEmail) |
| 87 | + -TsaCodebaseAdmin $(_TsaCodebaseAdmin) |
| 88 | + -TsaBugAreaPath $(_TsaBugAreaPath) |
| 89 | + -TsaIterationPath $(_TsaIterationPath) |
| 90 | + -TsaRepositoryName "wpf" |
| 91 | + -TsaCodebaseName "wpf" |
| 92 | + -TsaPublish $True' |
0 commit comments