-
-
Notifications
You must be signed in to change notification settings - Fork 5
46 lines (41 loc) · 1.05 KB
/
main.yml
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
name: Automation
on:
push:
branches: ['**']
release:
types: [published]
pull_request:
branches: ['**']
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install xvfb
run: sudo apt-get install xvfb
- name: Use Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install Dependencies
run: npm ci
- name: Test Lint
run: npm run lint
- name: Test Types
run: npm run types
- name: Build for Distribution
run: xvfb-run --auto-servernum npm run build
- name: Upload chrome extension
if: github.event_name != 'release'
uses: actions/upload-artifact@v4
with:
name: upload
path: .upload/
include-hidden-files: true
# Automatically attach files to release
- name: Upload to Release
if: github.event_name == 'release'
uses: softprops/action-gh-release@v2
with:
files: .upload/*