Skip to content

Separate docs build and deploy into separate workflows #121

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/docs-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Docs Build

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- name: Install Dependencies
run: |
python -m pip install -r docs/requirements.txt
- name: Build Docs
run: |
cd docs
make html
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: docs-build
path: docs/_build/html
27 changes: 27 additions & 0 deletions .github/workflows/docs-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Docs Deploy

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: docs-deploy
steps:
- name: Download Artifact
uses: actions/download-artifact@v4
with:
name: docs-build

# Note, the gh-pages deployment requires setting up a SSH deploy key.
# See
# https://github.com/JamesIves/github-pages-deploy-action/tree/dev#using-an-ssh-deploy-key-
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: .
ssh-key: ${{ secrets.DEPLOY_KEY }}
force: no
31 changes: 0 additions & 31 deletions .github/workflows/docs.yml

This file was deleted.