Skip to content

Merge pull request #2 from noelwelsh/main #1

Merge pull request #2 from noelwelsh/main

Merge pull request #2 from noelwelsh/main #1

Workflow file for this run

name: Continuous Integration
on:
pull_request:
branches: ["**", "!update/**", "!pr/**"]
push:
branches: ["**", "!update/**", "!pr/**"]
tags: [v*]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
concurrency:
group: ${{ github.workflow }} @ ${{ github.ref }}
cancel-in-progress: true
jobs:
site:
name: Generate Site
strategy:
matrix:
os: [ubuntu-latest]
java: [temurin@11]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Java (temurin@11)
id: setup-java-temurin-11
if: matrix.java == 'temurin@11'
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 11
cache: sbt
- name: sbt update
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false'
run: sbt +update
- name: Compile code
run: sbt fastLinkJS
- name: Setup npm
run: npm install
- name: Build project
run: npm run build
- name: Copy samples
run: cp -r resources dist/
- name: Publish site
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v4.0.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: dist
keep_files: true