Skip to content

Commit 0dc0358

Browse files
committed
ci build ext: publish to release asset, use same name convention as app, run only on main branch
1 parent 8048dd1 commit 0dc0358

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

.github/workflows/buildext.yaml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: Build Extension Zip
22

3-
on: push
3+
on:
4+
push:
5+
branches:
6+
- main
47

58
jobs:
69
release:
@@ -22,17 +25,19 @@ jobs:
2225
- name: Yarn Build
2326
run: yarn run build
2427

25-
- name: Create ZIP for Extension
26-
run: |
27-
cd dist/ext
28-
zip ../ext.zip -r ./
29-
3028
- name: Get Package Version
3129
id: package-version
3230
uses: martinbeentjes/npm-get-version-action@main
3331

32+
- name: Create ZIP for Extension
33+
run: |
34+
cd dist/ext
35+
zip ../../ArchiveWeb.page-${{ steps.package-version.outputs.current-version }}-extension.zip -r ./
36+
3437
- name: Upload Extension ZIP
35-
uses: actions/upload-artifact@v3
38+
uses: softprops/action-gh-release@v1
3639
with:
37-
name: archivewebpage-ext-${{ steps.package-version.outputs.current-version}}.zip
38-
path: dist/ext.zip
40+
files: ArchiveWeb.page-${{ steps.package-version.outputs.current-version }}-extension.zip
41+
tag_name: v${{ steps.package-version.outputs.current-version }}
42+
fail_on_unmatched_files: true
43+
draft: true

0 commit comments

Comments
 (0)