Skip to content

Commit 292243a

Browse files
committed
fix(docs): update post_checkout job to copy documentation based on project name
1 parent 486b095 commit 292243a

4 files changed

Lines changed: 8 additions & 54 deletions

File tree

.readthedocs.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,19 @@ build:
99
os: "ubuntu-24.04"
1010
tools:
1111
python: "3.13"
12-
1312
jobs:
1413
post_checkout:
15-
# Set up symbolic link based on RTD project name
14+
# Copy the appropriate conf.py based on project name
1615
- |
17-
if [ "$PROJECT_VERSION" = "brainpy-version2" ]; then
18-
ln -sf docs_version2 docs_build
16+
if [ "$READTHEDOCS_PROJECT" = "brainpy-version2" ]; then
17+
mkdir -p docs_build
18+
cp -r docs_version2/* docs_build/
1919
else
20-
ln -sf docs docs_build
20+
mkdir -p docs_build
21+
cp -r docs/* docs_build/
2122
fi
2223
23-
# Build documentation using the wrapper conf.py
24-
# The wrapper will dynamically load the correct docs based on READTHEDOCS_PROJECT
25-
# Build documentation using the symlinked directory
24+
# Build documentation using the copied conf.py
2625
sphinx:
2726
configuration: docs_build/conf.py
2827

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ We provide a Binder environment for BrainPy. You can use the following button to
7474

7575
## Citing
7676

77-
If you are using ``brainpy 2.0``, please consider citing the corresponding paper:
77+
If you are using ``brainpy``, please consider citing the corresponding paper:
7878

7979
```bibtex
8080
@article {10.7554/eLife.86365,

docs_build/conf.py

Lines changed: 0 additions & 45 deletions
This file was deleted.

docs_build/empty

Whitespace-only changes.

0 commit comments

Comments
 (0)