-
Notifications
You must be signed in to change notification settings - Fork 54
/
azure-pipelines.yml
104 lines (103 loc) · 3.47 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
name: $(date:yy)$(DayOfYear)$(rev:.r)
trigger:
branches:
include:
- main
pr:
branches:
include:
- main
drafts: false
variables:
TeamName: VS Core - IDE Experience
SolutionFile: ThemeConverter/ThemeConverter.sln
Platform: Any CPU
BuildConfiguration: Release
ProductBinariesFolder: '$(System.DefaultWorkingDirectory)/ThemeConverter/ThemeConverter/bin/$(BuildConfiguration)/net6.0'
VersionMajor: 0
VersionMinor: 1
AssemblyVersion: $(VersionMajor).$(VersionMinor).0.0
ProductVersion: $(VersionMajor).$(VersionMinor).$(Build.BuildNumber)
SignType: Test
CodeQL.Enabled: true
Codeql.TSAEnabled: false
Codeql.TSAOptionsPath: $(Build.SourcesDirectory)/.config/tsaoptions.json
resources:
repositories:
- repository: MicroBuildTemplate
type: git
name: 1ESPipelineTemplates/MicroBuildTemplate
ref: refs/tags/release
extends:
template: azure-pipelines/MicroBuild.1ES.Official.yml@MicroBuildTemplate
parameters:
sdl:
policheck:
enabled: true
tsa:
enabled: false
pool:
name: VSEngSS-MicroBuild2022-1ES
demands:
- msbuild
- VisualStudio_17.0
customBuildTags:
- ES365AIMigrationTooling
stages:
- stage: Build
jobs:
- job: Build_And_Compliance
displayName: Build and Compliance
templateContext:
mb:
signing:
enabled: true
signType: $(SignType)
feedSource: 'https://pkgs.dev.azure.com/devdiv/_packaging/MicroBuildToolset/nuget/v3/index.json'
sbom:
enabled: true
feedSource: 'https://pkgs.dev.azure.com/devdiv/_packaging/MicroBuildToolset/nuget/v3/index.json'
outputs:
- output: pipelineArtifact
displayName: 'Publish Staging Directory'
targetPath: $(Build.StagingDirectory)
steps:
- checkout: self
clean: true
- task: NuGetCommand@2
displayName: Restore NuGet Packages
inputs:
command: 'restore'
restoreSolution: $(SolutionFile)
- task: MSBuild@1
displayName: Build Product
inputs:
solution: $(SolutionFile)
platform: $(Platform)
configuration: $(BuildConfiguration)
msbuildArguments: /Property:Version=$(ProductVersion) /Property:FileVersion=$(ProductVersion) /Property:AssemblyVersion=$(AssemblyVersion) /Property:SignType=$(SignType)
continueOnError: false
- task: DotNetCoreCLI@2
displayName: Run Tests
inputs:
command: 'test'
projects: '**/ThemeConverterTests.csproj'
arguments: '--configuration Release'
- task: ArchiveFiles@2
displayName: Archive Binaries
inputs:
rootFolderOrFile: '$(ProductBinariesFolder)'
includeRootFolder: true
archiveType: 'zip'
archiveFile: '$(Build.StagingDirectory)/ThemeConverter-$(VersionMajor).$(VersionMinor).$(Build.BuildNumber).zip'
replaceExistingArchive: true
- task: ManifestGeneratorTask@0
displayName: 'Generation Task'
inputs:
BuildDropPath: '$(Build.StagingDirectory)'
- task: TSAUpload@2
displayName: 'TSA upload to Codebase (Theme Converter for VS)'
inputs:
GdnPublishTsaOnboard: True
GdnPublishTsaConfigFile: '$(Build.SourcesDirectory)/.config/tsaoptions.json'
condition: false