Skip to content

Commit 0d9bf09

Browse files
authored
new workflow
1 parent c346982 commit 0d9bf09

2 files changed

Lines changed: 61 additions & 2 deletions

File tree

.github/workflows/publish-new-addon-version.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ name: Publish new Firefox Add-on version
22

33
on:
44
workflow_dispatch: # Trigger workflow manually
5-
release:
6-
types: [published] # Trigger when a new release is published
5+
# release:
6+
# types: [published] # Trigger when a new release is published
77

88
permissions:
99
contents: read
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: "Release"
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- "v*.*.*"
8+
release:
9+
types: [published]
10+
11+
jobs:
12+
build:
13+
name: Build
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
with:
19+
fetch-depth: 0
20+
21+
- name: "web-ext build"
22+
id: web-ext-build
23+
uses: kewisch/action-web-ext@v1
24+
with:
25+
cmd: build
26+
filename: "{name}-{version}.xpi"
27+
# ignoreFiles: '[ "package.json","package-lock.json","yarn.lock", ".github", ".gitattributes", "LICENSE", "README.md" ]'
28+
ignoreFiles: |
29+
- package.json
30+
- package-lock.json
31+
- yarn.lock
32+
- .github
33+
- .gitattributes
34+
- LICENSE
35+
- README.md
36+
37+
- name: "web-ext sign"
38+
id: web-ext-sign
39+
uses: kewisch/action-web-ext@v1
40+
with:
41+
cmd: sign
42+
channel: listed
43+
source: ${{ steps.web-ext-build.outputs.target }}
44+
apiKey: ${{ secrets.FIREFOX_JWT_ISSUER }}
45+
apiSecret: ${{ secrets.FIREFOX_JWT_SECRET }}
46+
timeout: 900000
47+
48+
# - name: "Upload Artifact"
49+
# uses: actions/upload-artifact@v3
50+
# with:
51+
# name: target.xpi
52+
# path: ${{ steps.web-ext-build.outputs.target }}
53+
54+
- name: "Create Release"
55+
uses: softprops/action-gh-release@v2
56+
env:
57+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
58+
with:
59+
files: ${{ steps.web-ext-sign.outputs.target }}

0 commit comments

Comments
 (0)