82 строки
4.3 KiB
YAML
82 строки
4.3 KiB
YAML
version: 1.6.1-SNAPSHOT.{build}
|
|
|
|
environment:
|
|
securefile:
|
|
secure: Ytj1W9EwvU5JP+PlFUQ7CSing7qenLuDgUNbniX8BAY=
|
|
ossrh-user:
|
|
secure: T9zNd6DB0T6PXfUfxo5W2w==
|
|
ossrh-pass:
|
|
secure: 39ewTowxhIB09wMhP1rU+SJ6MahjvGTlJTO/VH+v8/M=
|
|
gpg-pass:
|
|
secure: t8UyjbNBnWJLrl8XFS/MbQ==
|
|
|
|
install:
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (set ProjectVersion=%APPVEYOR_REPO_TAG_NAME:~1%)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (nuget install secure-file -ExcludeVersion)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (secure-file\tools\secure-file -decrypt build\data\private_token.asc.enc -secret %securefile% -out build\data\private_token.asc)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (secure-file\tools\secure-file -decrypt build\data\public_token.asc.enc -secret %securefile% -out build\data\public_token.asc)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (secure-file\tools\secure-file -decrypt build\data\ownertrustblob.txt.enc -secret %securefile% -out build\data\ownertrustblob.txt)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (if not exist "%USERPROFILE%\.m2" mkdir %USERPROFILE%\.m2)
|
|
- cmd: IF "%APPVEYOR_REPO_TAG%" == "true" (powershell -NoProfile -ExecutionPolicy Bypass -Command "((Get-Content build\data\settings.xml) -replace '{user}', '%ossrh-user%' -replace '{pass}', '%ossrh-pass%' -replace '{passphrase}', '%gpg-pass%') | Set-Content %USERPROFILE%\.m2\settings.xml -force")
|
|
|
|
#build C# solution and scala project
|
|
build_script:
|
|
- cmd: echo [build_script] ProjectVersion=%ProjectVersion%
|
|
- cmd: echo appveyor environment BUILD_NUMBER=[%APPVEYOR_BUILD_NUMBER%] BUILD_VERSION=[%APPVEYOR_BUILD_VERSION%] REPO_TAG=[%APPVEYOR_REPO_TAG%] REPO_TAG_NAME=[%APPVEYOR_REPO_TAG_NAME%] APPVEYOR=[%APPVEYOR%] CI=[%CI%]
|
|
- cmd: SET MAVEN_OPTS=-XX:MaxPermSize=2g -Xmx4g
|
|
- cmd: SET JAVA_OPTS=-XX:MaxPermSize=2g -Xmx4g
|
|
- cmd: SET MVN_QUIET=--quiet
|
|
- ps: if($env:APPVEYOR_REPO_TAG -eq $FALSE) {.\dev\scripts\SetSparkClrNugetPackageVersion.ps1 -nuspecDir .\csharp -version $env:APPVEYOR_BUILD_VERSION}
|
|
- cmd: cd .\build
|
|
- cmd: .\Build.cmd
|
|
- cmd: cd ..
|
|
- cmd: dir .\build\target\*.zip
|
|
|
|
# need test section below - otherwise auto discovery will run samples will fail build (since it has no text fixtures)
|
|
test:
|
|
assemblies:
|
|
- csharp\AdapterTest\bin\Debug\AdapterTest.dll
|
|
- csharp\WorkerTest\bin\Debug\WorkerTest.dll
|
|
|
|
# scripts to run after tests
|
|
after_test:
|
|
- cmd: echo [after_test] ProjectVersion=%ProjectVersion%
|
|
- .\csharp\packages\OpenCover.4.6.166\tools\OpenCover.Console.exe -register:user -target:.\csharp\packages\NUnit.Console.3.0.1\tools\nunit3-console.exe -register:user "-targetargs:"".\csharp\WorkerTest\bin\Debug\WorkerTest.dll"" "".\csharp\AdapterTest\bin\Debug\AdapterTest.dll"" " -filter:"+[CSharpWorker*|Microsoft.Spark.CSharp*]*" -excludebyattribute:*.ExcludeFromCodeCoverage* -hideskipped:All -output:.\SparkCLRCodeCoverage.xml
|
|
- "SET PATH=C:\\Python34;C:\\Python34\\Scripts;%PATH%"
|
|
- pip install codecov
|
|
- codecov -f "SparkCLRCodeCoverage.xml"
|
|
- cmd: cd .\build\localmode
|
|
- cmd: .\Runsamples.cmd --validate
|
|
- cmd: cd ..\..
|
|
- cmd: dir csharp\Microsoft*.nupkg
|
|
- cmd: dir scala\target\spark-clr*.jar
|
|
|
|
artifacts:
|
|
- path: '**\Microsoft*.nupkg' # find all NuGet packages recursively
|
|
- path: 'scala\target\spark-clr*.jar'
|
|
- path: 'build\target\spark-clr*.zip'
|
|
|
|
deploy:
|
|
- provider: GitHub # deploy to GitHub releases
|
|
auth_token:
|
|
secure: 4JIzL2DO3OXXjdrso+VhA0RjMvUAg8BnZRHXojswaryXFe9mDJ3ExjssASWL1FZq
|
|
artifact: /spark-clr.*\.zip/
|
|
on:
|
|
appveyor_repo_tag: true # deploy on tag push only
|
|
|
|
- provider: NuGet # deploy to NuGet.org
|
|
api_key:
|
|
secure: TscZXMoOxrMfjR2TvGBns6b+IILWvo0WJpxikoGsMCqEcMj/x41Le1j8dHTCJMjI
|
|
skip_symbols: false
|
|
artifact: /Microsoft.*\.nupkg/
|
|
on:
|
|
appveyor_repo_tag: true # deploy on tag push only
|
|
|
|
- provider: NuGet # deploy to MyGet.org
|
|
server: https://www.myget.org/F/mobiusforspark/api/v2/package
|
|
api_key:
|
|
secure: 1c6+PZ3zOdIgIy2y8rf1g/NfbcfoxwNcymNBUr1591mD3Ull2X32Qvw2QyCXqFka
|
|
skip_symbols: false
|
|
symbol_server: https://www.myget.org/F/mobiusforspark/api/v2/package
|
|
artifact: /Microsoft.*\.nupkg/
|