Files
dotnet-packaging/appveyor.yml
2020-06-12 10:34:21 +02:00

47 lines
1.7 KiB
YAML

image: Visual Studio 2019
version: '0.1.{build}'
skip_branch_with_pr: true
before_build:
- dotnet restore dotnet-packaging.sln
build_script:
- dotnet pack dotnet-packaging.sln -c Release
test_script:
- cmd: cd %APPVEYOR_BUILD_FOLDER%\Packaging.Targets.Tests\
- cmd: dotnet restore
- cmd: dotnet build
- cmd: dotnet vstest bin\Debug\netcoreapp3.0\Packaging.Targets.Tests.dll /logger:trx;LogFileName=testresults.trx
- ps: '& (Join-Path $env:APPVEYOR_BUILD_FOLDER "appveyor-testresults.ps1")'
- cmd: cd ..
- cmd: set /p NuGetPackageVersion=<demo\version.txt
- cmd: dotnet tool install --global --add-source dotnet-tarball\bin\Release\ dotnet-tarball --version %NuGetPackageVersion%
- cmd: dotnet tool install --global --add-source dotnet-zip\bin\Release\ dotnet-zip --version %NuGetPackageVersion%
- cmd: dotnet tool install --global --add-source dotnet-rpm\bin\Release\ dotnet-rpm --version %NuGetPackageVersion%
- cmd: dotnet tool install --global --add-source dotnet-deb\bin\Release\ dotnet-deb --version %NuGetPackageVersion%
- cmd: cd %APPVEYOR_BUILD_FOLDER%/demo/aspnetcore
- cmd: dotnet restore
- cmd: dotnet rpm -c Release -r rhel.7-x64 -f netcoreapp3.0
- cmd: dotnet deb -c Release -r ubuntu.16.04-x64 -f netcoreapp3.0
artifacts:
- path: dotnet-tarball\bin\Release\dotnet-tarball.*nupkg
- path: dotnet-zip\bin\Release\dotnet-zip.*nupkg
- path: dotnet-rpm\bin\Release\dotnet-rpm.*nupkg
- path: dotnet-deb\bin\Release\dotnet-deb.*nupkg
- path: Packaging.Targets\bin\Release\Packaging.Targets.*nupkg
- path: demo\**\*.deb
- path: demo\**\*.rpm
deploy:
provider: NuGet
on:
branch: master
api_key:
secure: G26oZQpKHYN1Dr6pLjlaFp08zrS3ugIdNEnFxTyXvv/NEPvg7SsjBa0f9eNIKOlJ