1+ jobs :
2+ - job : Build
3+
4+ templateContext :
5+ outputs :
6+ - output : pipelineArtifact
7+ path : $(pkg_dir)
8+ artifact : drop
9+ sbomBuildDropPath : $(System.DefaultWorkingDirectory)
10+ sbomPackageName : ' DurableTask-Dotnet SBOM'
11+
12+ variables :
13+ project : ' src/dirs.proj'
14+ bin_dir : ' out/bin'
15+ log_dir : ' out/log'
16+ pkg_dir : ' out/pkg'
17+ build_args : -c release -p:FileVersionRevision=$(Build.BuildId) -p:ContinuousIntegrationBuild=true
18+ ${{ if parameters.binlog }} :
19+ build_binlog : -bl:$(log_dir)/build.binlog
20+ pack_binlog : -bl:$(log_dir)/pack.binlog
21+ ${{ else }} :
22+ build_binlog : ' '
23+ pack_binlog : ' '
24+
25+ steps :
26+ - checkout : self
27+ submodules : true
28+
29+ - task : UseDotNet@2
30+ displayName : ' Install .NET 6 SDK (ESRP)' # This is needed for ESRP.
31+ inputs :
32+ packageType : ' sdk'
33+ version : ' 6.x'
34+
35+ - task : UseDotNet@2
36+ displayName : ' Install .NET SDK (Build)' # This is needed for the build.
37+ inputs :
38+ packageType : ' sdk'
39+ useGlobalJson : true
40+
41+ # Start by restoring all the dependencies. This needs to be its own task.
42+ - task : DotNetCoreCLI@2
43+ displayName : Restore
44+ inputs :
45+ command : restore
46+ verbosityRestore : Minimal
47+ projects : $(project)
48+ feedsToUse : config
49+ nugetConfigPath : nuget.config
50+
51+ # Build source directory
52+ - task : DotNetCoreCLI@2
53+ displayName : Build
54+ inputs :
55+ command : build
56+ arguments : --no-restore $(build_args) $(build_binlog)
57+ projects : $(project)
58+
59+ - template : ci/sign-files.yml@eng
60+ parameters :
61+ displayName : Sign assemblies
62+ folderPath : $(bin_dir)
63+ pattern : Microsoft.DurableTask.*.dll
64+ signType : dll
65+
66+ # Packaging needs to be a separate step from build.
67+ # This will automatically pick up the signed DLLs.
68+ - task : DotNetCoreCLI@2
69+ displayName : Pack
70+ inputs :
71+ command : custom
72+ custom : pack
73+ arguments : --no-build $(build_args) $(pack_binlog)
74+ projects : $(project)
75+
76+ - template : ci/sign-files.yml@eng
77+ parameters :
78+ displayName : Sign NugetPackages
79+ folderPath : $(build.artifactStagingDirectory)
80+ pattern : ' *.nupkg'
81+ signType : nuget
0 commit comments