From 49e6596c9f259f23c9fe15a34c75d6c951ddd78e Mon Sep 17 00:00:00 2001 From: Daylin Morgan Date: Thu, 27 Apr 2023 09:07:59 -0500 Subject: [PATCH] ci: add docs workflow --- .github/workflows/docs.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/docs.yml diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 0000000..c044c08 --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,30 @@ +name: GitHub Pages + +on: + push: + tags: ["v*.*.*"] + workflow_dispatch: + +jobs: + deploy: + runs-on: ubuntu-22.04 + permissions: + contents: write + concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + steps: + - uses: actions/checkout@v3 + + - uses: jiro4989/setup-nim-action@v1 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + + - name: Build Docs + run: nimble docs + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + if: ${{ github.ref == 'refs/heads/main' }} + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./public