Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: simplify the build-test-pack-release process #535

Merged
merged 3 commits into from
Aug 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 19 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,31 @@
language: csharp
solution: Twilio.sln
dist: xenial
sudo: required
mono: none
dotnet: 2.1
mono: latest
dotnet: 3.1

env:
- FrameworkPathOverride=/usr/lib/mono/4.5/

services:
- docker

install:
- dotnet restore
- dotnet build --framework netstandard1.4 src/Twilio/Twilio.csproj
- dotnet build --framework netstandard2.0 src/Twilio/Twilio.csproj
- dotnet build --framework netcoreapp2.0 test/Twilio.Test/Twilio.Test.csproj

script:
- dotnet run --framework netcoreapp2.0 --project test/Twilio.Test/Twilio.Test.csproj
- make test
- make release

deploy:
provider: script
script: make docker-build && make docker-push
skip_cleanup: true
on:
tags: true
- provider: script
script: make docker-build && make docker-push
skip_cleanup: true
on:
branch: main
tags: true
- provider: script
script: dotnet nuget push **/*.nupkg -k $NUGET_API_KEY -s https://api.nuget.org/v3/index.json
skip_cleanup: true
on:
branch: main
tags: true

notifications:
slack:
Expand Down
12 changes: 4 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,11 @@ install:
dotnet restore

test:
dotnet restore
dotnet build --framework netstandard1.4 src/Twilio/Twilio.csproj
dotnet build --framework netstandard2.0 src/Twilio/Twilio.csproj
dotnet build --framework netcoreapp2.0 test/Twilio.Test/Twilio.Test.csproj
dotnet run --framework netcoreapp2.0 --project test/Twilio.Test/Twilio.Test.csproj

release: test
dotnet build -c Release
dotnet pack src/Twilio/Twilio.csproj -c Release -o .
dotnet test -c Release

release:
dotnet pack -c Release

docs:
doxygen Doxyfile
Expand Down
20 changes: 0 additions & 20 deletions appveyor.yml

This file was deleted.

87 changes: 0 additions & 87 deletions build.ps1

This file was deleted.

1 change: 1 addition & 0 deletions test/Twilio.Test/Twilio.Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<TargetFrameworks>netcoreapp2.0;net451;net35</TargetFrameworks>
<RuntimeIdentifier Condition=" '$(TargetFramework)' == 'net451' ">win7-x86</RuntimeIdentifier>
<RuntimeIdentifier Condition=" '$(TargetFramework)' == 'net35' ">win7-x86</RuntimeIdentifier>
<IsPackable>false</IsPackable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="NUnit" Version="3.6.0" />
Expand Down