-
Notifications
You must be signed in to change notification settings - Fork 593
38 lines (38 loc) · 1.01 KB
/
dashboard.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
name: Dashboard
on:
push:
branches: [main]
paths: [dashboard/**, proto/**]
pull_request:
branches: [main]
paths: [dashboard/**, proto/**]
workflow_dispatch:
jobs:
dashboard-ui-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
with:
node-version: "18"
- uses: arduino/setup-protoc@v1
with:
version: "3.x"
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: build
working-directory: ./dashboard
run: |
echo "::group::npm install"
npm install
echo "::endgroup::"
npm run lint
npm run build
- name: Deploy
uses: s0/git-publish-subdir-action@develop
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
env:
REPO: self
BRANCH: dashboard-artifact
FOLDER: dashboard/out
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SQUASH_HISTORY: true