wallabag/.github/workflows/assets.yml
Rotzbua 49e8619c01
Upgrade to NodeJS 18
* GH Actions: use cache
* GH Actions: use `.nvmrc`
2023-09-17 19:29:46 +02:00

46 lines
834 B
YAML

name: "Assets"
on:
pull_request:
push:
branches:
- master
- 2.*
permissions:
contents: read
jobs:
js:
name: "Building assets"
runs-on: "ubuntu-20.04"
steps:
- name: "Checkout"
uses: "actions/checkout@v4"
- name: "Install Node"
uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
cache: "yarn"
- name: "Install dependencies with Yarn"
run: "yarn install"
- name: "Build dev assets"
run: "yarn run build:dev"
- name: "Build prod assets"
run: "yarn run build:prod"
- name: "Validate no change were created"
run: |
GITDIFF=`git diff`
if [ "$GITDIFF" == "" ]; then
exit 0
else
git diff
exit 1
fi