workflows: Fix nested zip artifacts #3
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
build_for_release: | |
uses: ./.github/workflows/build.yml | |
release: | |
runs-on: ubuntu-latest | |
needs: build_for_release | |
permissions: | |
contents: write | |
steps: | |
- name: Download all workflow run artifacts | |
uses: actions/download-artifact@v4 | |
- name: Create firmware archive | |
run: | | |
for dir in *Release*/; do | |
pushd "${dir}" | |
zip -r "../${dir%/}.zip" . | |
popd | |
done | |
- name: Create release | |
uses: softprops/action-gh-release@v2 | |
with: | |
draft: true | |
prerelease: false | |
files: "*.zip" | |
fail_on_unmatched_files: true |