Skip to content

Commit 2b012ec

Browse files
cdeckerclaude
andcommitted
Add GitHub Pages documentation site with orchestrated workflows
This commit creates a comprehensive documentation publishing system that combines coverage reports, Python API docs, and project documentation into a unified GitHub Pages site. Changes: - Update coverage-nightly.yaml to support workflow_call trigger - Update python-docs-nightly.yaml to support workflow_call trigger - Add docs-nightly.yaml workflow for project documentation - Add publish-site.yaml orchestrator workflow The publish-site workflow: - Triggers all three documentation workflows in parallel - Collects artifacts from each workflow - Organizes them into a unified site structure: - / (root) - Beautiful landing page with navigation - /docs/ - Project documentation - /python/ - Python API reference (pdoc3) - /coverage/ - Code coverage reports - Deploys to GitHub Pages with proper permissions - Runs nightly at 5 AM UTC, after all other workflows complete Each workflow can be: - Triggered manually via workflow_dispatch - Called from other workflows via workflow_call - Run on schedule (coverage: 2 AM, python-docs: 3 AM, docs: 4 AM) The site includes: - Modern, responsive landing page with gradient design - Navigation cards for each documentation section - 404 error page - .nojekyll file to prevent Jekyll processing - Automatic timestamp updates 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> Changelog-None
1 parent 1d3fafa commit 2b012ec

File tree

4 files changed

+418
-0
lines changed

4 files changed

+418
-0
lines changed

.github/workflows/coverage-nightly.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ on:
66
- cron: '0 2 * * *'
77
# Allow manual triggers for testing
88
workflow_dispatch:
9+
# Allow being called from other workflows
10+
workflow_call:
911

1012
concurrency:
1113
group: coverage-${{ github.ref }}
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
name: Documentation (Nightly)
2+
3+
on:
4+
schedule:
5+
# Run at 4 AM UTC every day
6+
- cron: '0 4 * * *'
7+
# Allow manual triggers for testing
8+
workflow_dispatch:
9+
# Allow being called from other workflows
10+
workflow_call:
11+
12+
concurrency:
13+
group: docs-${{ github.ref }}
14+
cancel-in-progress: true
15+
16+
jobs:
17+
generate-docs:
18+
name: Generate Project Documentation
19+
runs-on: ubuntu-22.04
20+
21+
steps:
22+
- name: Checkout
23+
uses: actions/checkout@v4
24+
25+
- name: Prepare documentation directory
26+
run: |
27+
mkdir -p docs-output
28+
cp -r doc/* docs-output/
29+
30+
# Create a simple index.html for the documentation
31+
cat > docs-output/index.html <<'EOF'
32+
<!DOCTYPE html>
33+
<html>
34+
<head>
35+
<title>Core Lightning Documentation</title>
36+
<style>
37+
body {
38+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
39+
max-width: 1200px;
40+
margin: 0 auto;
41+
padding: 40px 20px;
42+
line-height: 1.6;
43+
}
44+
h1 {
45+
border-bottom: 2px solid #eaecef;
46+
padding-bottom: 0.3em;
47+
}
48+
.docs-list {
49+
list-style: none;
50+
padding: 0;
51+
}
52+
.docs-list li {
53+
padding: 8px 0;
54+
}
55+
.docs-list a {
56+
color: #0366d6;
57+
text-decoration: none;
58+
font-family: monospace;
59+
}
60+
.docs-list a:hover {
61+
text-decoration: underline;
62+
}
63+
.section {
64+
margin-top: 30px;
65+
}
66+
</style>
67+
</head>
68+
<body>
69+
<h1>Core Lightning Documentation</h1>
70+
<p>Welcome to the Core Lightning documentation site.</p>
71+
72+
<div class="section">
73+
<h2>Available Documentation</h2>
74+
<p>This site contains the complete documentation for Core Lightning.</p>
75+
<ul>
76+
<li><a href="../">← Back to main site</a></li>
77+
</ul>
78+
</div>
79+
80+
<div class="section">
81+
<p>For the full documentation, please visit the <a href="https://github.com/ElementsProject/lightning/tree/master/doc">doc directory on GitHub</a>.</p>
82+
</div>
83+
</body>
84+
</html>
85+
EOF
86+
87+
- name: Upload documentation artifact
88+
uses: actions/upload-artifact@v4
89+
with:
90+
name: project-docs
91+
path: docs-output
92+
retention-days: 90
93+
94+
- name: Add summary to job
95+
run: |
96+
echo "## Project Documentation Generated" >> $GITHUB_STEP_SUMMARY
97+
echo "" >> $GITHUB_STEP_SUMMARY
98+
echo "📖 Documentation files have been collected and prepared." >> $GITHUB_STEP_SUMMARY
99+
echo "" >> $GITHUB_STEP_SUMMARY
100+
echo "Download the artifact to view the documentation." >> $GITHUB_STEP_SUMMARY

0 commit comments

Comments
 (0)