Create build.yml

This commit is contained in:
2022-01-27 14:19:51 +02:00
committed by GitHub
parent 7852e98b4c
commit 47eb2f0a78

37
.github/workflows/build.yml vendored Normal file
View File

@@ -0,0 +1,37 @@
name: Build example page
on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build assets
run: |
npm install
npm run build --if-present
- name: Build GitHub Pages
# You may pin to the exact commit or the version.
# uses: crazy-max/ghaction-github-pages@a117e4aa1fb4854d021546d2abdfac95be568a3a
uses: crazy-max/ghaction-github-pages@v2.6.0
with:
build_dir: dist
jekyll: false