Skip to content

Commit 75e4e79

Browse files
committed
Improve docs pipeline
1 parent 67e9abb commit 75e4e79

File tree

2 files changed

+39
-24
lines changed

2 files changed

+39
-24
lines changed

.github/workflows/docs.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
name: Generate and Deploy Documentation
3+
4+
on:
5+
push:
6+
branches:
7+
- main # Or the branch you use for documentation
8+
pull_request:
9+
paths:
10+
- "docs/**" # Only trigger if there are changes in the documentation folder
11+
12+
jobs:
13+
build-docs:
14+
runs-on: ubuntu-latest
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
# Set up Python environment
20+
- name: Set up Python
21+
uses: actions/setup-python@v5
22+
with:
23+
python-version: 3.11
24+
25+
# Install dependencies
26+
- name: Install dependencies
27+
run: |
28+
pip install mkdocs==1.5.3 mkdocs-material pymdown-extensions mkdocs-minify-plugin
29+
30+
# Build the MkDocs site
31+
- name: Build MkDocs site
32+
run: mkdocs build
33+
34+
# Deploy to GitHub Pages
35+
- name: Deploy to GitHub Pages
36+
uses: peaceiris/actions-gh-pages@v4
37+
with:
38+
github_token: ${{ secrets.GITHUB_TOKEN }}
39+
publish_dir: site

.github/workflows/release.yml

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -39,27 +39,3 @@ jobs:
3939
generate_release_notes: true
4040
env:
4141
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42-
43-
44-
# Set up Python environment
45-
- name: Set up Python
46-
uses: actions/setup-python@v5
47-
with:
48-
python-version: 3.11
49-
50-
# Install dependencies
51-
- name: Install dependencies
52-
run: |
53-
pip install mkdocs==1.5.3 mkdocs-material pymdown-extensions mkdocs-minify-plugin
54-
55-
# Build the MkDocs site
56-
- name: Build MkDocs site
57-
run: mkdocs build
58-
59-
# Deploy to GitHub Pages
60-
- name: Deploy to GitHub Pages
61-
uses: peaceiris/actions-gh-pages@v4
62-
with:
63-
github_token: ${{ secrets.GITHUB_TOKEN }}
64-
publish_dir: site
65-

0 commit comments

Comments
 (0)