-
Notifications
You must be signed in to change notification settings - Fork 2
58 lines (47 loc) · 1.27 KB
/
release.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: Create Archive on Tag
on:
push:
tags:
- '*'
jobs:
build_and_archive:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js 21
uses: actions/setup-node@v4
with:
node-version: '21'
- name: Enable Corepack
working-directory: client
run: corepack enable
- name: Install dependencies
working-directory: client
run: yarn install
- name: Build project
working-directory: client
run: yarn build
- name: Create archives of dist folder
working-directory: client
run: |
zip -r dist.zip dist
tar -czvf dist.tar.gz dist
- name: Upload archives as artifacts
uses: actions/upload-artifact@v4
with:
name: dist.zip
path: client/dist.zip
- name: Upload tar.gz as artifact
uses: actions/upload-artifact@v4
with:
name: dist.tar.gz
path: client/dist.tar.gz
- name: Upload dist.zip and dist.tar.gz to the release
uses: svenstaro/upload-release-action@v2
with:
file: client/dist.*
file_glob: true
tag: ${{ github.ref_name }}
release_name: ${{ github.ref_name }}
repo_token: ${{ secrets.GITHUB_TOKEN }}