fapping.yaml 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. name: Build and Release FAP
  2. on:
  3. push:
  4. branches:
  5. - master
  6. - dev
  7. tags:
  8. - 'v*.*'
  9. permissions:
  10. contents: write
  11. jobs:
  12. build_master:
  13. if: github.ref == 'refs/heads/master'
  14. runs-on: ubuntu-latest
  15. steps:
  16. - name: Checkout code
  17. uses: actions/checkout@v4
  18. with:
  19. fetch-depth: 0
  20. lfs: true
  21. - name: Setup Python
  22. uses: actions/setup-python@v4
  23. with:
  24. python-version: '3.11'
  25. - name: Build Flipper Application Package (.fap)
  26. id: build-app
  27. uses: flipperdevices/flipperzero-ufbt-action@v0.1.4
  28. with:
  29. sdk-branch: 'release'
  30. - name: Upload app artifacts
  31. uses: actions/upload-artifact@v3
  32. with:
  33. name: ${{ github.event.repository.name }}-${{ steps.build-app.outputs.suffix }}
  34. path: ${{ steps.build-app.outputs.fap-artifacts }}
  35. - name: Create GitHub Release and Upload FAP
  36. uses: softprops/action-gh-release@v1
  37. if: startsWith(github.ref, 'refs/tags/')
  38. with:
  39. files: ${{ steps.build-app.outputs.fap-artifacts }}
  40. build_dev:
  41. if: github.ref == 'refs/heads/dev'
  42. runs-on: ubuntu-latest
  43. steps:
  44. - name: Checkout code
  45. uses: actions/checkout@v4
  46. with:
  47. fetch-depth: 0
  48. lfs: true
  49. - name: Setup Python
  50. uses: actions/setup-python@v4
  51. with:
  52. python-version: '3.11'
  53. - name: Build Flipper Application Package (.fap)
  54. id: build-app
  55. uses: flipperdevices/flipperzero-ufbt-action@v0.1.4
  56. with:
  57. sdk-branch: 'dev'
  58. - name: Upload app artifacts
  59. uses: actions/upload-artifact@v3
  60. with:
  61. name: ${{ github.event.repository.name }}-${{ steps.build-app.outputs.suffix }}
  62. path: ${{ steps.build-app.outputs.fap-artifacts }}
  63. - name: Create GitHub Release and Upload FAP
  64. uses: softprops/action-gh-release@v1
  65. if: startsWith(github.ref, 'refs/tags/')
  66. with:
  67. files: ${{ steps.build-app.outputs.fap-artifacts }}