Prepare release 0.26.0 #37
Workflow file for this run
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
| on: | |
| push: | |
| # Sequence of patterns matched against refs/tags | |
| tags: | |
| - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 | |
| name: Upload Release Asset | |
| jobs: | |
| build: | |
| name: Upload Release Asset | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Validate manifest.json (Chrome MV3) # should be compatible with Firefox too | |
| uses: cardinalby/schema-validator-action@v3 | |
| with: | |
| file: manifest.json | |
| schema: https://json.schemastore.org/chrome-manifest | |
| fixSchemas: true # <-- handles custom formats like "match-pattern" | |
| - name: Pack extension ZIP | |
| uses: TheDoctor0/zip-release@v0.3.0 | |
| with: | |
| filename: yt-better-subscriptions-latest.zip | |
| exclusions: '*.git* .editorconfig chrome_promo_tiles tests node_modules package.json package-lock.json jest.config.js coverage CLAUDE.md' | |
| - name: Generate checksums | |
| run: | | |
| sha256sum yt-better-subscriptions-latest.zip > SHA256SUMS.txt | |
| cat SHA256SUMS.txt | |
| - name: Get the version | |
| id: get_version | |
| run: echo "VERSION=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_OUTPUT | |
| - name: Create Release | |
| id: create_release | |
| uses: actions/create-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| tag_name: ${{ github.ref }} | |
| release_name: Release ${{ steps.get_version.outputs.VERSION }} | |
| draft: false | |
| prerelease: false | |
| - name: Upload Release Asset | |
| id: upload-release-asset | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps | |
| asset_path: ./yt-better-subscriptions-latest.zip | |
| asset_name: yt-better-subscriptions-${{ steps.get_version.outputs.VERSION }}.zip | |
| asset_content_type: application/zip | |
| - name: Upload checksums | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ steps.create_release.outputs.upload_url }} | |
| asset_path: ./SHA256SUMS.txt | |
| asset_name: SHA256SUMS.txt | |
| asset_content_type: text/plain | |
| # Publish to stores - disabled as its not working atm | |
| # - name: Publish on Chrome Webstore | |
| # uses: benc-uk/workflow-dispatch@4c044c1613fabbe5250deadc65452d54c4ad4fc7 # pin@v1 | |
| # if: "!contains(github.event.head_commit.message, '[skip chrome]')" | |
| # with: | |
| # workflow: publish-on-chrome-web-store | |
| # token: ${{ secrets.WORKFLOWS_TOKEN }} | |
| # inputs: '{ "tag": "${{ steps.get_version.outputs.VERSION }}" }' | |
| # | |
| # - name: Publish on Firefox Add-ons | |
| # uses: benc-uk/workflow-dispatch@4c044c1613fabbe5250deadc65452d54c4ad4fc7 # pin@v1 | |
| # if: "!contains(github.event.head_commit.message, '[skip firefox]')" | |
| # with: | |
| # workflow: publish-on-firefox-add-ons | |
| # token: ${{ secrets.WORKFLOWS_TOKEN }} | |
| # inputs: '{ "tag": "${{ steps.get_version.outputs.VERSION }}" }' | |
| # - name: Publish on Edge Add-ons | |
| # uses: benc-uk/workflow-dispatch@4c044c1613fabbe5250deadc65452d54c4ad4fc7 # pin@v1 | |
| # if: "!contains(github.event.head_commit.message, '[skip edge]')" | |
| # with: | |
| # workflow: publish-on-edge-add-ons | |
| # token: ${{ secrets.WORKFLOWS_TOKEN }} | |
| # inputs: '{ "tag": "${{ steps.get_version.outputs.VERSION }}" }' |