-
Notifications
You must be signed in to change notification settings - Fork 23
52 lines (41 loc) · 1.18 KB
/
build-statics.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
name: Node.js - Build & Auto-Commit to CLI data/report/**
on:
pull_request:
types:
- closed
# Trigger when PR is closed
paths:
- "static_report/**"
- "piperider_cli/**"
# Trigger when diffs detected in cli and report sources
branches:
- main
# Only PR target is `main`
jobs:
if_merged_build:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./static_report
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: 16
- uses: pnpm/[email protected]
with:
version: 7
- name: Install dependencies
working-directory: ./static_report
run: pnpm install --frozen-lockfile
- name: Build Apps
run: pnpm run build
- name: Pull Remote Changes (before AC)
run: git pull origin main
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: AUTO-COMMIT - build report statics to CLI data/report
branch: ${{ github.base_ref }}
# Auto-commits to target merge branch