build.yml 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137
  1. name: Build
  2. on: push
  3. jobs:
  4. build-windows-msi:
  5. name: Windows Build (MSI)
  6. runs-on: windows-latest
  7. steps:
  8. - name: Install Qt
  9. uses: jurplel/install-qt-action@v3
  10. with:
  11. version: 5.15.2
  12. arch: win32_msvc2019
  13. tools: tools_openssl_x86
  14. cache: true
  15. - name: Checkout Repo
  16. uses: actions/checkout@v3
  17. - name: Download Tools
  18. run: python scripts\download.py
  19. - name: Build MSI Package
  20. id: build
  21. shell: cmd
  22. run: |
  23. set QTDIR=%Qt5_DIR%
  24. set OPENSSL=%Qt5_DIR%/../../Tools/OpenSSL/Win_x86
  25. set PATH=%PATH%;C:\Program Files (x86)\WiX Toolset v3.11\bin
  26. call scripts\windows\packages\msi\build.msi.bat || exit
  27. set /p VERSION=<VERSION
  28. echo VERSION=%VERSION%>>%GITHUB_ENV%
  29. - name: Upload Assets
  30. uses: ncipollo/release-action@v1
  31. with:
  32. artifacts: apk-editor-studio_windows_${{ env.VERSION }}.msi
  33. artifactErrorsFailBuild: true
  34. allowUpdates: true
  35. omitName: true
  36. omitBody: true
  37. prerelease: true
  38. tag: development
  39. token: ${{ secrets.GITHUB_TOKEN }}
  40. build-windows-zip:
  41. name: Windows Build (ZIP)
  42. runs-on: windows-latest
  43. steps:
  44. - name: Install Qt
  45. uses: jurplel/install-qt-action@v3
  46. with:
  47. version: 5.15.2
  48. arch: win32_msvc2019
  49. tools: tools_openssl_x86
  50. cache: true
  51. - name: Checkout Repo
  52. uses: actions/checkout@v3
  53. - name: Download Tools
  54. run: python scripts\download.py
  55. - name: Build ZIP Package
  56. id: build
  57. shell: cmd
  58. run: |
  59. set QTDIR=%Qt5_DIR%
  60. set OPENSSL=%Qt5_DIR%/../../Tools/OpenSSL/Win_x86
  61. call "scripts\windows\packages\zip\build.zip.bat" || exit
  62. set /p VERSION=<VERSION
  63. echo VERSION=%VERSION%>>%GITHUB_ENV%
  64. - name: Upload Assets
  65. uses: ncipollo/release-action@v1
  66. with:
  67. artifacts: apk-editor-studio_windows_${{ env.VERSION }}.zip
  68. artifactErrorsFailBuild: true
  69. allowUpdates: true
  70. omitName: true
  71. omitBody: true
  72. prerelease: true
  73. tag: development
  74. token: ${{ secrets.GITHUB_TOKEN }}
  75. build-linux-appimage:
  76. name: Linux Build (AppImage)
  77. runs-on: ubuntu-18.04
  78. steps:
  79. - name: Install Dependencies
  80. run: |
  81. sudo add-apt-repository ppa:beineri/opt-qt-5.15.2-bionic -y
  82. sudo apt-get update -qq
  83. sudo apt-get install qt515base qt515imageformats qt515svg qt515tools libgl1-mesa-dev libsecret-1-dev adb zipalign
  84. - name: Checkout Repo
  85. uses: actions/checkout@v3
  86. - name: Download Tools
  87. run: python3 scripts/download.py
  88. - name: Build AppImage Package
  89. id: build
  90. run: |
  91. source /opt/qt515/bin/qt515-env.sh || true
  92. scripts/linux/packages/appimage/build.appimage.sh
  93. echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV
  94. - name: Upload Assets
  95. uses: ncipollo/release-action@v1
  96. with:
  97. artifacts: scripts/linux/packages/appimage/apk-editor-studio_linux_${{ env.VERSION }}.AppImage
  98. artifactErrorsFailBuild: true
  99. allowUpdates: true
  100. omitName: true
  101. omitBody: true
  102. prerelease: true
  103. tag: development
  104. token: ${{ secrets.GITHUB_TOKEN }}
  105. build-macos:
  106. name: macOS Build (APP, DMG)
  107. runs-on: macos-latest
  108. steps:
  109. - name: Install Qt
  110. uses: jurplel/install-qt-action@v3
  111. with:
  112. version: 5.15.2
  113. cache: true
  114. - name: Checkout Repo
  115. uses: actions/checkout@v3
  116. - name: Download Tools
  117. run: python3 scripts/download.py
  118. - name: Build APP/DMG Package
  119. id: build
  120. run: |
  121. scripts/macos/packages/app/build.app.command
  122. npm i appdmg
  123. scripts/macos/packages/dmg/build.dmg.command
  124. echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV
  125. - name: Upload Assets
  126. uses: ncipollo/release-action@v1
  127. with:
  128. artifacts: scripts/macos/packages/app/apk-editor-studio_macos_${{ env.VERSION }}.app.zip,scripts/macos/packages/dmg/apk-editor-studio_macos_${{ env.VERSION }}.dmg
  129. artifactErrorsFailBuild: true
  130. allowUpdates: true
  131. omitName: true
  132. omitBody: true
  133. prerelease: true
  134. tag: development
  135. token: ${{ secrets.GITHUB_TOKEN }}