fix docs deployment branch (#2) #6
This file contains 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
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- master | |
env: | |
PACK_DIR: /root/.pack | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
container: ghcr.io/stefan-hoeck/idris2-pack | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build docs | |
run: | | |
apt-get update && apt-get install -y curl python3-venv | |
pack --no-prompt run plasma.ipkg | |
python3 -m venv .venv | |
. .venv/bin/activate | |
pip install -r plot/requirements.txt -c plot/constraints.txt | |
python3 plot/plot.py | |
mkdir docs | |
mv index.html docs/ | |
- name: Upload docs | |
run: | | |
git config --global --add safe.directory "$GITHUB_WORKSPACE" | |
git add -f docs/ | |
git config user.email "none" | |
git config user.name "none" | |
git commit -m "build documentation" | |
git push -f origin HEAD:gh-pages |