release #6
This file contains hidden or 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 | |
| # Semantic Versioning (MAJOR.MINOR.PATCH): | |
| # - MAJOR: Breaking changes | |
| # - MINOR: New features, backwards-compatible | |
| # - PATCH: Bug fixes, backwards-compatible | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| tag: | |
| description: 'Tag to release (e.g., 1.32.0)' | |
| required: true | |
| type: string | |
| draft: | |
| description: 'Create as draft release' | |
| required: false | |
| type: boolean | |
| default: true | |
| prerelease: | |
| description: 'Mark as pre-release' | |
| required: false | |
| type: boolean | |
| default: true | |
| jobs: | |
| build: | |
| uses: ./.github/workflows/build.yml | |
| release: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Create and push tag | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git tag ${{ github.event.inputs.tag }} | |
| git push origin ${{ github.event.inputs.tag }} | |
| - name: Download binary artifact | |
| uses: actions/download-artifact@v6 | |
| with: | |
| name: color-led-binary | |
| path: ./artifacts | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: ${{ github.event.inputs.tag }} | |
| name: Release ${{ github.event.inputs.tag }} | |
| draft: ${{ github.event.inputs.draft }} | |
| prerelease: ${{ github.event.inputs.prerelease }} | |
| files: ./artifacts/color-led.bin |