Skip to content

deno deploy docs

deno deploy docs #2

Workflow file for this run

name: Docs
on:
push:
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- name: install mdbook
run: curl https://github.com/rust-lang/mdBook/releases/download/v0.4.43/mdbook-v0.4.43-x86_64-unknown-linux-gnu.tar.gz -L | tar -xz
- run: mv docs/theme/{prod-,}toc.js.hbs
- run: ../mdbook build
working-directory: docs
- run: find docs/book -iname '*.html' -exec sed -e 's#\.html##g' -e 's#/index#/#g' -i -- {} ';'
- if: github.ref_name == 'main'
uses: actions/configure-pages@v3
- if: github.ref_name == 'main'
uses: actions/upload-pages-artifact@v2
with:
path: docs/static
- if: github.ref_name == 'main'
uses: actions/deploy-pages@v1
- run: rm docs/static/docs; mv docs/book docs/static/docs
- if: github.ref_name != 'main'
uses: denoland/deployctl@v1
with:
project: vine-dev
root: docs/static
entrypoint: https://deno.land/std/http/file_server.ts