resources: - repo: self clean: true variables: SamplesBin: SamplesBin WINDOWS_WINMD: C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.17763.0\Windows.winmd strategy: maxParallel: 8 matrix: Release_x64: BuildPlatform: x64 BuildConfiguration: Release Debug_x64: BuildPlatform: x64 BuildConfiguration: Debug Release_x86: BuildPlatform: x86 BuildConfiguration: Release Debug_x86: BuildPlatform: x86 BuildConfiguration: Debug pool: name: Package ES Lab E # demands: agent.osversion -equals 10.0.17763 # CI trigger trigger: branches: include: - master paths: exclude: - Tools # PR validation trigger pr: branches: include: - master paths: exclude: - Tools steps: - task: PowerShell@2 displayName: 'Check SDK Version 17763 is present' inputs: targetType: inline script: dir "${ENV:programfiles(x86)}\windows Kits\10\include\10.0.17763.0\" - task: DotNetCoreInstaller@0 displayName: 'Use .NET Core sdk 2.1.300' inputs: version: 2.1.300 condition: succeededOrFailed() - task: NuGetToolInstaller@0 displayName: 'Use NuGet 4.9.2' inputs: versionSpec: 4.9.2 condition: succeededOrFailed() - task: 333b11bd-d341-40d9-afcf-b32d5ce6f23b@2 displayName: 'NuGet restore' condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build UI test solution Testing/**/SamplesTest.sln' inputs: solution: 'Testing/**/SamplesTest.sln' vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\SamplesTest\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build AdapterSelection Sample' inputs: solution: Samples/AdapterSelection/AdapterSelection.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\AdapterSelection\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build CustomOperatorCPU Sample' inputs: solution: Samples/CustomOperatorCPU/desktop/cpp/custom-operator-cpu-sample.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\CustomOperatorCPU\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build MNIST-Tutorial-cs Sample' inputs: solution: 'Samples/MNIST/Tutorial/cs/mnist_demo.sln' vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\MNIST-Tutorial\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build MNIST-UWP-cs Sample' inputs: solution: 'Samples/MNIST/UWP/cs/mnist_demo.sln' vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\MNIST-cs\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build SqueezenetObjectDetection Sample' inputs: solution: Samples/SqueezeNetObjectDetection/squeezenetobjectdetection.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\SqueezeNetObjectDetection\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build FNSCandyStyleTransfer-UWP-CS Sample' inputs: solution: Samples/FNSCandyStyleTransfer/UWP/CS/snapcandy.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\FNSCandyStyleTransfer\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build MNIST-UWP-cppcx Sample' inputs: solution: 'Samples/MNIST/UWP/cppcx/mnist_cppcx.sln' vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\MNIST-cppcx\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build CustomTensorization Sample' inputs: solution: Samples/CustomTensorization/CustomTensorization.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\CustomTensorization\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: VSBuild@1 displayName: 'Build Emoji Sample' inputs: solution: Samples/Emoji8/UWP/cs/Emoji8.sln vsVersion: 15.0 msbuildArgs: '-v:diag /p:OutDir=$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\Emoji8\' platform: '$(BuildPlatform)' configuration: '$(BuildConfiguration)' clean: true msbuildArchitecture: x64 createLogFile: true condition: succeededOrFailed() - task: CopyFiles@2 inputs: targetFolder: '$(Build.ArtifactStagingDirectory)\$(BuildPlatform)\$(BuildConfiguration)\' sourceFolder: '$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\' Contents: | **\SamplesTest\** **\AppPackages\** condition: succeededOrFailed() - task: CopyFiles@2 inputs: targetFolder: '$(Build.ArtifactStagingDirectory)\$(BuildPlatform)\$(BuildConfiguration)\' sourceFolder: '$(System.DefaultWorkingDirectory)\bin\$(BuildPlatform)\$(BuildConfiguration)\' Contents: | ?(AdapterSelection|CustomOperatorCPU|CustomTensorization)**\* SqueezeNetObjectDetection\* condition: succeededOrFailed() - task: CopyFiles@2 inputs: targetFolder: '$(Build.ArtifactStagingDirectory)\$(BuildPlatform)\$(BuildConfiguration)\SharedContent' sourceFolder: 'SharedContent' contents: '**\*' condition: succeededOrFailed() - task: PublishBuildArtifacts@1 displayName: 'Publish Artifact: Samples' inputs: pathtoPublish: '$(Build.ArtifactStagingDirectory)' artifactName: WinMLPublicSamples-RS5 condition: succeededOrFailed()