appveyor.yml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. environment:
  2. matrix:
  3. - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
  4. platform: Win64
  5. configuration:
  6. - Release
  7. cache:
  8. - c:/Users/appveyor/.sw -> appveyor.yml
  9. only_commits:
  10. files:
  11. - appveyor.yml
  12. - '**.cpp'
  13. - '**.h'
  14. - 'unittest/**.c'
  15. - 'unittest/**.cc'
  16. before_build:
  17. - git submodule update --init --recursive
  18. - curl -fsS -L -o dl.zip https://software-network.org/client/sw-master-windows_x86_64-client.zip
  19. - 7z x dl.zip
  20. - set PATH=%PATH%;%cd%
  21. build_script:
  22. - sw -version
  23. # -show-output - show command output
  24. # debug build causes long builds (> 1h), appveyor drops them
  25. - sw -platform %platform% -config r build -Dwith-tests=1
  26. # test
  27. - git clone https://github.com/egorpugin/tessdata tessdata_unittest
  28. - ps: Copy-Item -Path "tessdata_unittest\fonts\*" -Destination "test\testing" -Recurse
  29. - sw -platform %platform% -config r test -Dwith-tests=1 -Dskip-tests=lstm,lstm_recode
  30. after_build:
  31. - 7z a tesseract.zip %APPVEYOR_BUILD_FOLDER%\.sw\out\**\*.exe %APPVEYOR_BUILD_FOLDER%\.sw\out\**\*.dll
  32. #- 7z a tesseract.zip %APPVEYOR_BUILD_FOLDER%\.sw\Windows_*_Shared_Release_MSVC_*\*.exe %APPVEYOR_BUILD_FOLDER%\.sw\Windows_*_Shared_Release_MSVC_*\*.dll
  33. on_finish:
  34. # gather tests
  35. - ps: $wc = New-Object 'System.Net.WebClient'
  36. - ps: $wc.UploadFile("https://ci.appveyor.com/api/testresults/junit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .\.sw\test\results.xml))
  37. artifacts:
  38. - path: tesseract.zip
  39. name: tesseract-$(APPVEYOR_BUILD_VERSION)