Skip to content

add leaderboard link at the front page #44

add leaderboard link at the front page

add leaderboard link at the front page #44

name: publish-website
on:
# Trigger the workflow on push to main branch
push:
branches:
- main
workflow_dispatch:
permissions:
contents: write
jobs:
build:
# uses: ProjectPythia/cookbook-actions/.github/workflows/build-book.yaml@main
# until https://github.com/ProjectPythia/cookbook-actions/pull/65 is merged
# FIXME: I keep running into this annoying issue that I cannot use a PR to an existing public workflow. Very frustrating
# uses: jbusecke/cookbook-actions/.github/workflows/build-book.yaml@patch-4
# So the only way to fix this rn is to manually copy the PR content here and reference it locally. Silly.
uses: ./.github/workflows/build-book.yaml
with:
environment_file: 'website/environment.yml'
environment_name: chaosbench-docs-env
path_to_notebooks: 'website'
build_command: 'cp -r ../README.md ../docs .; jupyter-book build .'
# this is a bit hacky, but the only way to 'inject' a shell command before the build.
output_path: '_build/html'
deploy:
needs: build
#Trying this out to see if the auth problem is fixed
# uses: ./.github/workflows/deploy-book.yaml #hack until https://github.com/ProjectPythia/cookbook-actions/pull/45 is merged.
uses: ProjectPythia/cookbook-actions/.github/workflows/deploy-book.yaml@main
with:
publish_dir: "website/_build/html"