-
Notifications
You must be signed in to change notification settings - Fork 32
29 lines (29 loc) · 864 Bytes
/
docs.yml
File metadata and controls
29 lines (29 loc) · 864 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: docs
on:
push:
branches:
- master
workflow_dispatch:
permissions:
contents: write
env:
nim-src: src/pixie.nim
deploy-dir: .gh-pages
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: treeform/setup-nim-action@v6
- name: Install dependencies
run: |
cd ..
nimby install -g pixie/pixie.nimble
- run: nim doc --index:on --project --git.url:https://github.com/${{ github.repository }} --git.commit:master --out:${{ env.deploy-dir }} ${{ env.nim-src }}
- name: Copy to index.html
run: cp ${{ env.deploy-dir }}/pixie.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 }}