Skip to content

Commit b00e653

Browse files
authored
Update generate-docs.yml to debug and verify docs directory
- Added debugging steps to list the root directory and the contents of the docs directory during the workflow. - Ensured actions/checkout fetches the full repository with fetch-depth set to 0. - Updated sphinx-build step to use a relative path for the docs directory. - This update addresses potential path recognition issues and ensures the docs directory is properly located and used during the workflow.
1 parent 8bb1041 commit b00e653

File tree

1 file changed

+14
-36
lines changed

1 file changed

+14
-36
lines changed
Lines changed: 14 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,35 @@
1-
name: Automated Documentation
1+
name: Generate Documentation
22

33
on:
44
push:
5-
pull_request:
5+
branches:
6+
- main
67

78
jobs:
89
generate-docs:
9-
name: Generate or Update Documentation
1010
runs-on: ubuntu-latest
1111

1212
steps:
13-
# Checkout repository code
1413
- name: Checkout code
1514
uses: actions/checkout@v3
16-
17-
# Set up Node.js for JSDoc or Python for Sphinx
18-
- name: Set up Node.js
19-
if: ${{ contains(github.event.head_commit.message, 'js') }}
20-
uses: actions/setup-node@v3
2115
with:
22-
node-version: '16'
16+
fetch-depth: 0
17+
18+
- name: Debug root directory
19+
run: ls -R
20+
21+
- name: Debug docs directory
22+
run: ls docs
2323

2424
- name: Set up Python
25-
if: ${{ contains(github.event.head_commit.message, 'py') }}
2625
uses: actions/setup-python@v4
2726
with:
28-
python-version: '3.10'
27+
python-version: 3.10
2928

30-
# Install dependencies for Sphinx or JSDoc
31-
- name: Install Sphinx dependencies
32-
if: ${{ contains(github.event.head_commit.message, 'sphinx') }}
29+
- name: Install Sphinx
3330
run: |
3431
python -m pip install --upgrade pip
3532
pip install sphinx sphinx-rtd-theme
3633
37-
- name: Install JSDoc dependencies
38-
if: ${{ contains(github.event.head_commit.message, 'jsdoc') }}
39-
run: npm install jsdoc
40-
41-
# Generate documentation
42-
- name: Generate Sphinx Documentation
43-
if: ${{ contains(github.event.head_commit.message, 'sphinx') }}
44-
run: |
45-
sphinx-build -b html docs/ build/
46-
47-
- name: Generate JSDoc Documentation
48-
if: ${{ contains(github.event.head_commit.message, 'jsdoc') }}
49-
run: |
50-
npx jsdoc -c jsdoc.conf.json
51-
52-
# Deploy documentation (optional)
53-
- name: Deploy Documentation
54-
if: always()
55-
run: |
56-
echo "Deploying generated documentation"
57-
# Add your deployment logic here (e.g., pushing to GitHub Pages)
34+
- name: Build Documentation
35+
run: sphinx-build -b html docs/ build/

0 commit comments

Comments
 (0)