Sync to test-website. Fix up README. #53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test-deploy | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
test: | |
strategy: | |
matrix: | |
os: [ubuntu-22.04, macos-14] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 22 | |
- run: | | |
shopt -s extglob nullglob globstar | |
if: runner.os == 'Linux' | |
- name: run-test | |
run: | | |
yarn install | |
yarn install-website article | |
set -x -e | |
yarn bundle-website article | |
export PUPPETEER_CACHE_DIR=$GITHUB_WORKSPACE/ | |
# requires Puppeteer to be installed at same version as used in Fluid | |
yarn puppeteer browsers install chrome | |
yarn puppeteer browsers install firefox | |
yarn test-website article | |
deploy-website: | |
runs-on: ubuntu-22.04 | |
needs: test | |
# Use branch 'website' to experiment with deploy-website | |
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/website' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: build | |
run: | | |
yarn install | |
set -x -e | |
yarn install-website article | |
yarn bundle-website article | |
- name: gh-pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: dist/article | |
keep_files: false |