mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
add build.sh
This commit is contained in:
parent
5ac70c587c
commit
1bfe42ea67
2 changed files with 33 additions and 1 deletions
|
|
@ -3,4 +3,6 @@ sudo: required
|
|||
dist: trusty
|
||||
solution: FilterLists.sln
|
||||
mono: none
|
||||
dotnet: 1.0.1
|
||||
dotnet: 1.0.1
|
||||
script:
|
||||
- ./build.sh
|
||||
30
build.sh
Normal file
30
build.sh
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
#!/usr/bin/env bash
|
||||
# https://andrewlock.net/adding-travis-ci-to-a-net-core-app/
|
||||
|
||||
# exit if any command fails
|
||||
set -e
|
||||
|
||||
artifactsFolder="./artifacts"
|
||||
|
||||
if [ -d $artifactsFolder ]; then
|
||||
rm -R $artifactsFolder
|
||||
fi
|
||||
|
||||
dotnet restore
|
||||
|
||||
# Ideally we would use the 'dotnet test' command to test netcoreapp and net451 so restrict for now
|
||||
# but this currently doesn't work due to https://github.com/dotnet/cli/issues/3073 so restrict to netcoreapp
|
||||
|
||||
# dotnet test ./test/TEST_PROJECT_NAME -c Release -f netcoreapp1.0
|
||||
|
||||
# Instead, run directly with mono for the full .net version
|
||||
# dotnet build ./test/TEST_PROJECT_NAME -c Release -f net451
|
||||
|
||||
# mono \
|
||||
# ./test/TEST_PROJECT_NAME/bin/Release/net451/*/dotnet-test-xunit.exe \
|
||||
# ./test/TEST_PROJECT_NAME/bin/Release/net451/*/TEST_PROJECT_NAME.dll
|
||||
|
||||
revision=${TRAVIS_JOB_ID:=1}
|
||||
revision=$(printf "%04d" $revision)
|
||||
|
||||
dotnet pack ./src/FilterLists.Api.csproj -c Release -o ./artifacts --version-suffix=$revision
|
||||
Loading…
Reference in a new issue