Skip to content

v0.7.0

v0.7.0 #8

Workflow file for this run

name: Generate docs
on:
# Run when a release is published
release:
types:
- published
jobs:
generate-docs:
name: Generate docs
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
steps:
- name: Check out the repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # ratchet:actions/checkout@v4
- name: Install Roc
uses: hasnep/setup-roc@9866c6fdc971ee9f4b3eeba03d825dc32a5efa7f # ratchet:hasnep/[email protected]
with:
roc-version: 0.0.0-alpha2-rolling
- name: Generate docs
run: roc docs src/main.roc
- name: Fix absolute paths
run: |
find generated-docs/ -type f -name '*.html' -exec sed -i "s/\(href\|src\)=\"\//\1=\"\/${{ github.event.repository.name }}\//g" {} +
- name: Upload docs artifact
uses: actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa # ratchet:actions/upload-pages-artifact@v3
with:
path: generated-docs
- name: Deploy docs
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # ratchet:actions/deploy-pages@v4