Skip to content

tests

tests #13

Workflow file for this run

name: gh-pages
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
timeout-minutes: 240
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v4
- uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: texlive-xetex
version: 1.0
- uses: actions/setup-node@v3
with:
node-version: 21
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.100-preview.1.24101.2'
- uses: moonrepo/setup-rust@v1
with:
inherit-toolchain: true
- uses: actions/setup-go@v5
- uses: actions/setup-python@v4
with:
python-version: '3.12'
- uses: actions/cache@v3
with:
path: ~/.nuget/packages
key: ${{ runner.os }}-nuget2-${{ hashFiles('**/paket.lock') }}
restore-keys: ${{ runner.os }}-nuget2-
- uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-2024-04-23-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-2024-04-23-
- run: pwsh scripts/init.ps1
- run: pwsh scripts/publish.ps1
- uses: actions/upload-artifact@v2
with:
name: gh-pages
path: dist
retention-days: 30
push:
needs: build
timeout-minutes: 60
runs-on: ubuntu-latest
env:
FLEEK_TOKEN: ${{ secrets.FLEEK_TOKEN }}
FLEEK_PROJECT_ID: ${{ secrets.FLEEK_PROJECT_ID }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v2
with:
name: gh-pages
path: gh-pages
- id: hash
run: echo "::set-output name=hash::$(git rev-parse HEAD)"
- uses: peaceiris/actions-gh-pages@v3
if: ${{ steps.hash.outputs.hash != github.event.before }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: gh-pages
- uses: actions/setup-node@v3
with:
node-version: 20
- if: ${{ steps.hash.outputs.hash != github.event.before }}
run: pwsh gh-pages/scripts/publish-fleek.ps1