diff --git a/.github/workflows/build_sw.yml b/.github/workflows/build_sw.yml index 46b4ff5..867fdfa 100644 --- a/.github/workflows/build_sw.yml +++ b/.github/workflows/build_sw.yml @@ -48,7 +48,34 @@ jobs: name: build_files path: ${{github.workspace}}/Software/build - release: + release-dev: + if: github.ref == 'refs/heads/dev' # Only deploy on 'dev' branch + runs-on: ubuntu-latest + needs: build + steps: + - name: Download build files artifact + uses: actions/download-artifact@v4 + with: + name: build_files + + - name: Display structure of downloaded files + run: ls + + - name: Release + uses: softprops/action-gh-release@v2 + if: startsWith(github.ref, 'refs/tags/') + with: + prerelease: true + files: | + RP2040-Decoder.bin + RP2040-Decoder.dis + RP2040-Decoder.elf + RP2040-Decoder.elf.map + RP2040-Decoder.hex + RP2040-Decoder.uf2 + + release-main: + if: github.ref == 'refs/heads/main' # Only deploy on 'main' branch runs-on: ubuntu-latest needs: build steps: @@ -71,5 +98,3 @@ jobs: RP2040-Decoder.elf.map RP2040-Decoder.hex RP2040-Decoder.uf2 - -