image: Visual Studio 2017
version: '{branch}-{build}'
pull_requests:
  do_not_increment_build_number: true
before_build:
- dotnet restore
- choco install codecov
build_script:
- dotnet build src --configuration release
- dotnet pack --configuration release --include-symbols -o ../nupkgs/ src
test_script:
- dotnet test test /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:CoverletOutput="../coverage.xml"
- codecov -f "coverage.xml"
artifacts:
- path: .\nupkgs\**\*.nupkg
  name: nuget
deploy:
- provider: NuGet
  server: nuget.org
  api_key:
    secure: tjJ2B5WQ2buXosN2GvPoAbkAxZlWrLwSaxzAgTpemaYQFywrr1FrqD/Wrr7rBVZA
  on:
    APPVEYOR_REPO_TAG: true

image: Visual Studio 2017
version: '{branch}-{build}'
pull_requests:
  do_not_increment_build_number: true
init:
 - ps: >-
    if ($env:APPVEYOR_REPO_TAG -eq "true")
    {
        Update-AppveyorBuild -Version "$($env:APPVEYOR_REPO_TAG_NAME.TrimStart("v"))"
    }
dotnet_csproj:
  patch: true
  file: 'src\*.csproj'
  version: '{version}'
before_build:
- dotnet restore
- choco install codecov
build_script:
- dotnet build src --configuration release
- dotnet pack --configuration release --include-symbols -o ../nupkgs/ src
test_script:
- dotnet test test /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:CoverletOutput='../coverage.xml'
- codecov -f 'coverage.xml'
artifacts:
- path: '.\nupkgs\**\*.nupkg'
  name: nuget
deploy:
- provider: NuGet
  server: nuget.org
  api_key:
    secure: tjJ2B5WQ2buXosN2GvPoAbkAxZlWrLwSaxzAgTpemaYQFywrr1FrqD/Wrr7rBVZA
  on:
    APPVEYOR_REPO_TAG: true

Add csproj patching on tags
chore(ci): Add csproj patching on tags
