build-validation.yml 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. name: Build Validation
  2. on:
  3. push:
  4. branches: [ v2_release, v2_develop ]
  5. paths-ignore:
  6. - '**.md'
  7. pull_request:
  8. branches: [ v2_release, v2_develop ]
  9. paths-ignore:
  10. - '**.md'
  11. jobs:
  12. build-validation:
  13. name: Build All Configurations
  14. runs-on: ubuntu-latest
  15. timeout-minutes: 10
  16. steps:
  17. - name: Checkout code
  18. uses: actions/checkout@v4
  19. - name: Setup .NET Core
  20. uses: actions/setup-dotnet@v4
  21. with:
  22. dotnet-version: 8.x
  23. dotnet-quality: 'ga'
  24. - name: Restore dependencies
  25. run: dotnet restore
  26. # Suppress CS0618 (member is obsolete) and CS0612 (member is obsolete without message)
  27. # Using -property: syntax with URL-encoded semicolon (%3B) to avoid shell interpretation issues
  28. - name: Build Debug
  29. run: dotnet build --configuration Debug --no-restore -property:NoWarn=0618%3B0612
  30. - name: Build Release Terminal.Gui
  31. run: dotnet build Terminal.Gui/Terminal.Gui.csproj --configuration Release --no-incremental --force -property:NoWarn=0618%3B0612
  32. - name: Pack Release Terminal.Gui
  33. run: dotnet pack Terminal.Gui/Terminal.Gui.csproj --configuration Release --output ./local_packages -property:NoWarn=0618%3B0612
  34. - name: Restore AOT and Self-Contained projects
  35. run: |
  36. dotnet restore ./Examples/NativeAot/NativeAot.csproj -f
  37. dotnet restore ./Examples/SelfContained/SelfContained.csproj -f
  38. - name: Restore Solution Packages
  39. run: dotnet restore
  40. - name: Build Release AOT and Self-Contained
  41. run: |
  42. dotnet build ./Examples/NativeAot/NativeAot.csproj --configuration Release -property:NoWarn=0618%3B0612
  43. dotnet build ./Examples/SelfContained/SelfContained.csproj --configuration Release -property:NoWarn=0618%3B0612
  44. - name: Build Release Solution
  45. run: dotnet build --configuration Release --no-restore -property:NoWarn=0618%3B0612