From 6ca0cbe5ae91d868ca568f945ea77c516f78b065 Mon Sep 17 00:00:00 2001 From: Toni Hermoso Pulido Date: Mon, 2 Dec 2024 17:05:23 +0100 Subject: [PATCH] adding docs workflow --- .github/workflows/docs.yml | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 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..4e1e663 --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,37 @@ +name: Docs +on: + workflow_dispatch: + push: + paths: + - 'docs/**' + pull_request: + paths: + - 'docs/**' +jobs: + build: + runs-on: ubuntu-22.04 + steps: + - id: deployment + uses: sphinx-notes/pages@v3 + with: + publish: false + - uses: peaceiris/actions-gh-pages@v4 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + destination_dir: ${{ github.ref_name }} + publish_dir: ${{ steps.deployment.outputs.artifact }} + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.repository.default_branch }} + - uses: actions/checkout@v4 + with: + ref: gh-pages + path: gh-pages + - name: Copy file + run: | + cp ./assets/docs/index.html ./gh-pages/ + - name: Deploy to GitHub Pages + uses: peaceiris/actions-gh-pages@v4 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./gh-pages