21 lines
664 B
YAML
21 lines
664 B
YAML
image: mcr.microsoft.com/dotnet/core/sdk:2.1
|
|
stages:
|
|
- test
|
|
- deploy
|
|
|
|
lyokocmd-tests:
|
|
stage: test
|
|
before_script:
|
|
- dotnet restore
|
|
script:
|
|
- dotnet test test/LyokoCMD.Sim.Tests
|
|
|
|
lyokocmd-deploy:
|
|
stage: deploy
|
|
only:
|
|
- master@Lucidiot/LyokoCMD
|
|
script:
|
|
- dotnet pack --version-suffix latest
|
|
- find . -type f -name '*.nupkg' -not -path '*/.git/*' | sed -r 's/^.*\/([^\/]+)\.nupkg$/\1/;s/^([^0-9]+)\.([0-9.]+(-[a-zA-Z0-9]+)?)$/\1 \2/' | xargs -n2 dotnet nuget delete --non-interactive -k $NUGET_API_KEY || /bin/true
|
|
- find . -type f -name '*.nupkg' -not -path '*/.git/*' | xargs -n1 -I '{}' dotnet nuget push {} -k $NUGET_API_KEY
|