Skip to content

Commit cd0c204

Browse files
Leooo-Huangclaude
andcommitted
fix: resolve MkDocs build errors — use build-docs staging directory
- docs_dir cannot be repo root (MkDocs rejects parent-of-config) - site_dir cannot be inside docs_dir (causes recursive copy) - Solution: CI copies needed files into build-docs/ before building - Updated nav paths to match new directory structure Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c7b1632 commit cd0c204

2 files changed

Lines changed: 43 additions & 9 deletions

File tree

.github/workflows/mkdocs.yml

Lines changed: 36 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
branches:
66
- main
7+
workflow_dispatch:
78

89
permissions:
910
contents: write
@@ -23,7 +24,40 @@ jobs:
2324
python-version: "3.12"
2425

2526
- name: Install dependencies
26-
run: pip install -r requirements-docs.txt
27+
run: pip install mkdocs-material
28+
29+
- name: Prepare docs directory
30+
run: |
31+
mkdir -p build-docs/datasets/vision
32+
mkdir -p build-docs/datasets/skeleton
33+
mkdir -p build-docs/datasets/wearable
34+
mkdir -p build-docs/datasets/multimodal
35+
mkdir -p build-docs/datasets/emerging
36+
mkdir -p build-docs/resources
37+
mkdir -p build-docs/assets
38+
39+
# Copy homepage
40+
cp docs/index.md build-docs/index.md
41+
42+
# Copy all dataset cards
43+
cp datasets/vision/*.md build-docs/datasets/vision/
44+
cp datasets/skeleton/*.md build-docs/datasets/skeleton/
45+
cp datasets/wearable/*.md build-docs/datasets/wearable/
46+
cp datasets/multimodal/*.md build-docs/datasets/multimodal/
47+
cp datasets/emerging/*.md build-docs/datasets/emerging/
48+
49+
# Copy resource docs
50+
cp docs/taxonomy.md build-docs/resources/taxonomy.md
51+
cp docs/surveys.md build-docs/resources/surveys.md
52+
cp docs/benchmarking.md build-docs/resources/benchmarking.md
53+
cp docs/roadmap.md build-docs/resources/roadmap.md
54+
55+
# Copy contributing and README
56+
cp CONTRIBUTING.md build-docs/contributing.md
57+
cp README.md build-docs/readme-source.md
58+
59+
# Copy assets
60+
cp -r assets/* build-docs/assets/ 2>/dev/null || true
2761
2862
- name: Deploy to GitHub Pages
29-
run: mkdocs gh-deploy --force
63+
run: mkdocs gh-deploy --force --config-file mkdocs.yml

mkdocs.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ site_url: "https://leo-cyberautonomy.github.io/awesome-human-activity-recognitio
33
repo_url: "https://github.com/Leo-Cyberautonomy/awesome-human-activity-recognition"
44
repo_name: "Leo-Cyberautonomy/awesome-human-activity-recognition"
55

6-
docs_dir: "."
6+
docs_dir: "build-docs"
77
site_dir: "site"
88

99
theme:
@@ -24,7 +24,7 @@ plugins:
2424
- search
2525

2626
nav:
27-
- Home: docs/index.md
27+
- Home: index.md
2828
- Datasets:
2929
- Vision:
3030
- Kinetics-700: datasets/vision/kinetics-700.md
@@ -85,11 +85,11 @@ nav:
8585
- InterX: datasets/emerging/interx.md
8686
- WiMANS: datasets/emerging/wimans.md
8787
- Resources:
88-
- Taxonomy: docs/taxonomy.md
89-
- Surveys: docs/surveys.md
90-
- Benchmarking: docs/benchmarking.md
91-
- Contributing: CONTRIBUTING.md
92-
- Roadmap: docs/roadmap.md
88+
- Taxonomy: resources/taxonomy.md
89+
- Surveys: resources/surveys.md
90+
- Benchmarking: resources/benchmarking.md
91+
- Contributing: contributing.md
92+
- Roadmap: resources/roadmap.md
9393

9494
markdown_extensions:
9595
- tables

0 commit comments

Comments
 (0)