docs: Update readme to include docs link #3
Workflow file for this run
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
name: docs | |
on: | |
push: | |
tags: | |
- '*.*.*' | |
permissions: | |
contents: write | |
env: | |
nim-version: 'stable' | |
nim-src: src/${{ github.event.repository.name }}.nim | |
deploy-dir: .gh-pages | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: jiro4989/setup-nim-action@v1 | |
with: | |
nim-version: ${{ env.nim-version }} | |
- run: nimble install -Y | |
- run: nimble doc --index:on --project --git.commit=main --git.devel=main --git.url="https://github.com/penguinite/expect" --out:${{ env.deploy-dir }} ${{ env.nim-src }} | |
- name: "Rename to index.html" | |
run: mv ${{ env.deploy-dir }}/${{ github.event.repository.name }}.html ${{ env.deploy-dir }}/index.html | |
- name: Deploy documents | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ${{ env.deploy-dir }} |