on:
push:
branches: [master]
tags:
- "v*.*.*"
jobs:
release:
permissions:
contents: write
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- run: npm ci
- run: npm run build
- if: startsWith(github.ref, 'refs/tags/')
run: npm run sign -- --api-key ${{ secrets.MOZILLA_JWT_ISSUER }} --api-secret ${{ secrets.MOZILLA_JWT_SECRET }}
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: build
path: |
web-ext-artifacts
- name: Create release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
fail_on_unmatched_files: true
generate_release_notes: true
draft: false
prerelease: false
files: |
web-ext-artifacts/*