Skip to content

Instantly share code, notes, and snippets.

@amr-swalha
Created July 28, 2019 15:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save amr-swalha/56717bca9dbe91c25222f23bc3dde8ab to your computer and use it in GitHub Desktop.
Save amr-swalha/56717bca9dbe91c25222f23bc3dde8ab to your computer and use it in GitHub Desktop.
The build yaml file
trigger:
- master
pool:
vmImage: 'windows-latest'
steps:
- script: dotnet restore
displayName: 'nuget is restoring'
- script: dotnet build --configuration $(buildConfiguration)
displayName: 'dotnet build $(buildConfiguration)'
- task: DotNetCoreCLI@2
displayName: Running Unit Tests
inputs:
command: 'test'
- task: DotNetCoreCLI@2
displayName: Publish Web Project
inputs:
command: 'publish'
publishWebProjects: true
arguments: --configuration $(buildConfiguration) --output $(build.artifactstagingdirectory)
zipAfterPublish: true
- task: PublishBuildArtifacts@1
displayName: Create publish artifact
inputs:
PathtoPublish: '$(build.artifactstagingdirectory)'
ArtifactName: 'drop'
publishLocation: 'Container'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment