|
| 1 | +# Template for build + pack on dnceng |
| 2 | +parameters: |
| 3 | +- name: pool |
| 4 | + type: object |
| 5 | +- name: enableSourceBuild |
| 6 | + type: boolean |
| 7 | + default: false |
| 8 | +- name: enableSourceIndex |
| 9 | + type: boolean |
| 10 | + default: false |
| 11 | +- name: sourceIndexParams |
| 12 | + type: object |
| 13 | + default: [] |
| 14 | +- name: publishTaskPrefix |
| 15 | + type: string |
| 16 | + default: '1ES.' |
| 17 | + |
| 18 | +stages: |
| 19 | +- stage: Pack |
| 20 | + displayName: Pack .NET MAUI |
| 21 | + dependsOn: [] |
| 22 | + jobs: |
| 23 | + - template: /eng/common/templates-official/jobs/jobs.yml |
| 24 | + parameters: |
| 25 | + helixRepo: dotnet/maui |
| 26 | + pool: ${{ parameters.pool }} |
| 27 | + enableMicrobuild: true |
| 28 | + enablePublishUsingPipelines: true |
| 29 | + enablePublishBuildAssets: true |
| 30 | + enableTelemetry: true |
| 31 | + enableSourceBuild: ${{ parameters.enableSourceBuild }} |
| 32 | + enableSourceIndex: ${{ parameters.enableSourceIndex }} |
| 33 | + sourceIndexParams: ${{ parameters.sourceIndexParams }} |
| 34 | + publishAssetsImmediately: true |
| 35 | + enablePublishBuildArtifacts: true |
| 36 | + enablePublishTestResults: true |
| 37 | + workspace: |
| 38 | + clean: all |
| 39 | + jobs: |
| 40 | + - job: pack_net_Windows |
| 41 | + displayName: Pack Windows |
| 42 | + timeoutInMinutes: 240 |
| 43 | + preSteps: |
| 44 | + - checkout: self |
| 45 | + fetchDepth: 1 |
| 46 | + clean: true |
| 47 | + steps: |
| 48 | + - template: /eng/pipelines/common/setup-jdk.yml |
| 49 | + |
| 50 | + - script: $(_buildScript) |
| 51 | + -restore -build |
| 52 | + -configuration $(_BuildConfig) |
| 53 | + /p:ArchiveTests=true |
| 54 | + /p:TreatWarningsAsErrors=false |
| 55 | + /bl:$(Build.Arcade.LogsPath)build.binlog |
| 56 | + $(_OfficialBuildIdArgs) |
| 57 | + displayName: 🛠️ Build |
| 58 | + |
| 59 | + # Run on public pipeline |
| 60 | + - ${{ if eq(variables['_RunAsPublic'], 'true') }}: |
| 61 | + - script: $(_buildScript) |
| 62 | + -restore -pack |
| 63 | + -publish $(_PublishArgs) |
| 64 | + -configuration $(_BuildConfig) |
| 65 | + /bl:$(Build.Arcade.LogsPath)pack.binlog |
| 66 | + $(_OfficialBuildIdArgs) |
| 67 | + displayName: Pack & Publish |
| 68 | + |
| 69 | + # Run on internal pipeline |
| 70 | + - ${{ if eq(variables['_RunAsInternal'], 'true') }}: |
| 71 | + - script: $(_buildScript) |
| 72 | + -restore -pack |
| 73 | + -sign $(_SignArgs) |
| 74 | + -publish $(_PublishArgs) |
| 75 | + -configuration $(_BuildConfig) |
| 76 | + /bl:$(Build.Arcade.LogsPath)pack.binlog |
| 77 | + $(_OfficialBuildIdArgs) |
| 78 | + displayName: Pack, Sign & Publish |
| 79 | + |
| 80 | + # only for workloads |
| 81 | + - script: $(_buildScript) |
| 82 | + -restore -build |
| 83 | + -sign $(_SignArgs) |
| 84 | + -publish $(_PublishArgs) |
| 85 | + -configuration $(_BuildConfig) |
| 86 | + /bl:$(Build.Arcade.LogsPath)/build-workloads.binlog |
| 87 | + -projects src/Workload/workloads.csproj |
| 88 | + $(_OfficialBuildIdArgs) |
| 89 | + displayName: Build Workloads |
| 90 | + |
| 91 | + - task: ${{ parameters.publishTaskPrefix }}PublishPipelineArtifact@1 |
| 92 | + displayName: Publish VSDrop MSIs |
| 93 | + inputs: |
| 94 | + targetPath: '$(Build.SourcesDirectory)/artifacts/VSSetup/$(_BuildConfig)' |
| 95 | + artifactName: VSDropInsertion |
0 commit comments