77 demands :
88 - ImageOverride -equals MMS2022TLS
99
10+ parameters :
11+ - name : binlog
12+ displayName : MSBuild binary log
13+ type : boolean
14+ default : false
15+
1016variables :
1117 project : ' src/dirs.proj'
18+ bin_dir : ' out/bin'
19+ log_dir : ' out/log'
20+ pkg_dir : ' out/pkg'
21+ build_args : -c release -p:FileVersionRevision=$(Build.BuildId) -p:ContinuousIntegrationBuild=true
22+ ${{ if parameters.binlog }} :
23+ build_binlog : -bl:$(log_dir)/build.binlog
24+ pack_binlog : -bl:$(log_dir)/pack.binlog
1225
1326steps :
1427- checkout : self
@@ -22,18 +35,18 @@ steps:
2235
2336# Start by restoring all the dependencies. This needs to be its own task.
2437- task : DotNetCoreCLI@2
25- displayName : ' Restore'
38+ displayName : Restore
2639 inputs :
2740 command : restore
2841 verbosityRestore : Minimal
2942 projects : $(project)
3043
3144# Build source directory
3245- task : DotNetCoreCLI@2
33- displayName : ' Build'
46+ displayName : Build
3447 inputs :
3548 command : build
36- arguments : --no-restore -c release -p:FileVersionRevision=$(Build.BuildId) -p:ContinuousIntegrationBuild=true
49+ arguments : --no-restore $(build_args) $(build_binlog)
3750 projects : $(project)
3851
3952# Authenticode sign all the DLLs with the Microsoft certificate.
4255 displayName : ' ESRP CodeSigning: Authenticode'
4356 inputs :
4457 ConnectedServiceName : ' ESRP Service'
45- FolderPath : ' out/bin '
58+ FolderPath : $(bin_dir)
4659 Pattern : ' Microsoft.DurableTask.*.dll'
4760 signConfigType : inlineSignParams
4861 inlineOperation : |
@@ -78,22 +91,20 @@ steps:
7891# Packaging needs to be a separate step from build.
7992# This will automatically pick up the signed DLLs.
8093- task : DotNetCoreCLI@2
81- displayName : Generate nuget packages
94+ displayName : Pack
8295 inputs :
83- command : pack
84- verbosityPack : Minimal
85- configuration : release
86- nobuild : true
87- packDirectory : $(build.artifactStagingDirectory)
88- packagesToPack : $(project)
96+ command : custom
97+ custom : pack
98+ arguments : --no-build $(build_args) $(pack_binlog)
99+ projects : $(project)
89100
90101# Digitally sign all the nuget packages with the Microsoft certificate.
91102# This appears to be an in-place signing job, which is convenient.
92103- task : SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@2
93104 displayName : ' ESRP CodeSigning: Nupkg'
94105 inputs :
95106 ConnectedServiceName : ' ESRP Service'
96- FolderPath : $(build.artifactStagingDirectory )
107+ FolderPath : $(pkg_dir )
97108 Pattern : ' *.nupkg'
98109 signConfigType : inlineSignParams
99110 inlineOperation : |
@@ -115,6 +126,10 @@ steps:
115126 ]
116127
117128# Make the nuget packages available for download in the ADO portal UI
118- - publish : $(build.artifactStagingDirectory)
119- displayName : ' Publish nuget packages to Artifacts'
120- artifact : PackageOutput
129+ - publish : $(pkg_dir)
130+ displayName : ' Publish packages to Artifacts'
131+ artifact : pkg
132+
133+ - publish : $(log_dir)
134+ displayName : ' Publish logs to Artifacts'
135+ artifact : log
0 commit comments