2020-07-28 23:12:40 +00:00
|
|
|
name: build
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- safe.fiery.me
|
|
|
|
paths:
|
2020-07-29 22:09:08 +00:00
|
|
|
- 'src/**/*.css'
|
|
|
|
- 'src/**/*.js'
|
|
|
|
- 'src/**/*.scss'
|
2020-08-24 05:34:28 +00:00
|
|
|
- 'src/versions.json'
|
2020-07-28 23:12:40 +00:00
|
|
|
|
2022-05-06 15:21:56 +00:00
|
|
|
env:
|
2022-10-08 01:54:05 +00:00
|
|
|
NODE_VERSION: 18
|
2022-05-06 15:21:56 +00:00
|
|
|
|
2020-07-28 23:12:40 +00:00
|
|
|
jobs:
|
|
|
|
build:
|
2021-01-08 19:55:41 +00:00
|
|
|
name: Rebuild client assets and bump v1 version string
|
2023-04-23 01:55:36 +00:00
|
|
|
runs-on: ubuntu-22.04
|
2020-07-28 23:12:40 +00:00
|
|
|
steps:
|
2023-09-06 09:50:42 +00:00
|
|
|
- uses: actions/checkout@v4
|
2020-07-29 22:09:08 +00:00
|
|
|
|
|
|
|
- name: Use Node.js
|
2023-12-05 23:22:04 +00:00
|
|
|
uses: actions/setup-node@v4
|
2020-07-29 22:09:08 +00:00
|
|
|
with:
|
2022-05-06 15:21:56 +00:00
|
|
|
node-version: ${{ env.NODE_VERSION }}
|
|
|
|
|
|
|
|
- name: Cache node_modules
|
2022-05-06 19:12:54 +00:00
|
|
|
uses: actions/cache@v3
|
2022-05-06 15:21:56 +00:00
|
|
|
id: cache-nodemodules
|
|
|
|
with:
|
|
|
|
path: node_modules
|
|
|
|
key: ${{ runner.os }}-${{ env.NODE_VERSION }}-nodemodules-${{ hashFiles('**/yarn.lock') }}
|
2020-07-29 22:09:08 +00:00
|
|
|
|
|
|
|
- name: Install dependencies
|
2022-05-06 15:21:56 +00:00
|
|
|
if: steps.cache-nodemodules.outputs.cache-hit != 'true'
|
|
|
|
run: yarn install --frozen-lockfile --non-interactive
|
2020-07-29 22:09:08 +00:00
|
|
|
|
2022-03-03 11:03:48 +00:00
|
|
|
- name: Update browserslist/caniuse-lite
|
|
|
|
run: npx browserslist@latest --update-db
|
|
|
|
|
2020-07-29 22:09:08 +00:00
|
|
|
- name: yarn build
|
|
|
|
run: yarn build
|
|
|
|
|
2023-10-14 03:18:29 +00:00
|
|
|
- uses: stefanzweifel/git-auto-commit-action@v5
|
2020-07-29 22:09:08 +00:00
|
|
|
with:
|
2021-01-08 19:55:41 +00:00
|
|
|
commit_message: 'dist: rebuilt client assets and bumped v1 version string'
|
2020-08-24 05:32:54 +00:00
|
|
|
commit_user_name: loli-bot
|
|
|
|
commit_user_email: hi@fiery.me
|
2020-07-29 22:09:08 +00:00
|
|
|
env:
|
|
|
|
CI: true
|