main.yml 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. name: UFBT Build and Test
  2. on:
  3. push:
  4. branches:
  5. - main
  6. pull_request:
  7. branches:
  8. - main
  9. jobs:
  10. build:
  11. name: Build and Upload Application
  12. runs-on: ubuntu-latest
  13. steps:
  14. - name: Checkout Repository
  15. uses: actions/checkout@v3
  16. - name: Set up Python
  17. uses: actions/setup-python@v4
  18. with:
  19. python-version: '3.x'
  20. - name: Install UFBT
  21. run: |
  22. python3 -m pip install --upgrade pip
  23. pip install ufbt
  24. - name: Initialize UFBT Environment
  25. run: |
  26. ufbt update
  27. ufbt vscode_dist
  28. - name: Build FAP Applications
  29. run: ufbt faps
  30. - name: Debug asset name
  31. run: echo "Uploading file: metroflip-${{ github.sha }}.fap"
  32. - name: Upload FAP to Release
  33. uses: actions/upload-release-asset@v1
  34. with:
  35. upload_url: ${{ steps.create_release.outputs.upload_url }}
  36. asset_path: /home/runner/.ufbt/build/metroflip.fap
  37. asset_name: metroflip-${{ github.sha }}.fap
  38. asset_content_type: application/octet-stream