Skip to content

Commit 07256a3

Browse files
committed
fix internal links
Signed-off-by: Shubham Kumar <chmodshubham@gmail.com>
1 parent d14a059 commit 07256a3

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

.github/workflows/deploy-docs.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,8 @@ jobs:
6363
- name: Add .nojekyll file and create index.html
6464
run: |
6565
touch _build/html/.nojekyll
66-
# Create index.html from the main index file for GitHub Pages
67-
if [ -f "_build/html/index" ]; then
68-
cp _build/html/index _build/html/index.html
69-
fi
66+
# Create index.html files for all directories
67+
find _build/html -name "index" -type f -exec sh -c 'cp "$1" "${1%index}index.html"' _ {} \;
7068
7169
- name: Verify build output
7270
run: |

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ html:
3838
html-github:
3939
. $(VENV); export GITHUB_ACTIONS=true; $(SPHINXBUILD) -c . -b dirhtml "$(SOURCEDIR)" "$(BUILDDIR)" -w .sphinx/warnings.txt --keep-going
4040
touch "$(BUILDDIR)/.nojekyll"
41-
if [ -f "$(BUILDDIR)/index" ]; then cp "$(BUILDDIR)/index" "$(BUILDDIR)/index.html"; fi
41+
# Create index.html files for all directories
42+
find "$(BUILDDIR)" -name "index" -type f -exec sh -c 'cp "$$1" "$${1%index}index.html"' _ {} \;
4243

4344
epub:
4445
. $(VENV); $(SPHINXBUILD) -c . -b epub "$(SOURCEDIR)" "$(BUILDDIR)" -w .sphinx/warnings.txt

0 commit comments

Comments
 (0)