-
Notifications
You must be signed in to change notification settings - Fork 7
Add Zensical documentation site #35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Set up a documentation site using the Zensical framework with automatic content extraction from README.md using markdown-code-runner. - Add SECTION markers to README.md for content extraction - Create docs_gen.py module to extract and transform README sections - Add docs/ directory with pages (index, getting-started, examples, etc.) - Add run_markdown_code_runner.py script to update all docs files - Add GitHub Actions workflow for docs deployment - Add zensical.toml configuration - Add docs dependencies to pyproject.toml - Add site/ to .gitignore for build output
Track fence delimiter character and length to correctly handle nested fences (e.g., ```` containing ```). Previously, a simple toggle would incorrectly treat inner ``` as a fence boundary.
Instead of escaping markers with zero-width spaces, docs templates now contain placeholders in OUTPUT sections. The content is generated during CI build and never committed. Benefits: - No escaping logic needed (removed ~70 lines of complex fence detection) - Templates in repo are clean and copyable - No zero-width space characters anywhere - Simpler and more maintainable Changes: - docs_gen.py: Remove escaping, add --reset and --verify commands - docs/*.md: Reset OUTPUT sections to placeholders - docs.yml: Add verify and generate steps before build - pre-commit: Add hook to prevent committing processed content
- Remove pip caching section (uv handles caching automatically) - Use Python API instead of subprocess for processing files - Use PEP 723 inline script dependencies with uv shebang
The OUTPUT placeholder now explains why we don't commit generated content: to keep docs copyable and avoid recursion issues.
Check for <!-- PLACEHOLDER --> marker instead of full text, so the explanatory message can be updated without breaking verification.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Changes
docs_gen.pymodule to extract and transform README sectionsdocs/directory with pages:index.md- Home page with features and introgetting-started.md- Installation and quick startexamples.md- Usage examples from READMEcontributing.md- Contributing guideusage/python-api.md- Python API documentationusage/cli.md- CLI referenceusage/github-actions.md- GitHub Actions integrationrun_markdown_code_runner.pyscript to update all docs fileszensical.tomlconfigurationTest plan
uv run zensical buildNotes
docs-sitebranch for testingdocs-sitefrom deploy conditions in.github/workflows/docs.yml