Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ venv.bak/
# Rope project settings
.ropeproject

# mkdocs documentation
# Zensical documentation
/site

# mypy
Expand Down
53 changes: 23 additions & 30 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Deploy MkDocs to GitHub Pages
name: Deploy documentation to GitHub Pages

on:
push:
Expand All @@ -9,59 +9,52 @@ on:
- 'docs/**'
- 'archipy/**'
- 'packages/**'
- 'mkdocs*.yml'
- 'pyproject.toml'
- 'uv.lock'
- '.python-version'
- '.github/workflows/deploy-docs.yml'
pull_request:
paths:
- 'mkdocs*.yml'
- '.python-version'
- '.github/workflows/deploy-docs.yml'

permissions:
contents: read

jobs:
deployment-smoke-test:
if: github.event_name == 'pull_request'
build:
runs-on: ubuntu-latest
container: &uv-image ghcr.io/astral-sh/uv:0.13.9-trixie
steps: &deployment-steps
container: ghcr.io/astral-sh/uv:0.13.9-trixie
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 0 # Fetch all history for proper versioning
persist-credentials: ${{ github.event_name == 'push' }}

- name: Cache uv dependencies
uses: actions/cache@v5
with:
path: ~/.cache/uv
key: uv-docs-deploy-${{ runner.arch }}-${{ hashFiles('.python-version', 'uv.lock') }}
persist-credentials: false

- name: Install dependencies
run: uv sync --locked --group docs

- name: Configure Git user
run: |
# Checkout only trusts the runner-owned workspace in its temporary Git config.
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
- name: Build documentation
run: uv run --no-sync zensical build --clean -f mkdocs-full.yml

- name: Deploy documentation
run: |
if [ "$GITHUB_EVENT_NAME" = pull_request ]; then
git init --bare "$RUNNER_TEMP/docs-deploy.git"
git remote add deployment-test "$RUNNER_TEMP/docs-deploy.git"
set -- --remote-name deployment-test
fi
uv run --no-sync mkdocs gh-deploy --force -f docs/mkdocs-full.yml "$@"
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v5
with:
path: site

deploy:
if: github.event_name == 'push'
needs: build
runs-on: ubuntu-latest
container: *uv-image
permissions:
contents: write
steps: *deployment-steps
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v5
1 change: 1 addition & 0 deletions .github/workflows/docs-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
branches: [ '*' ]
paths:
- 'docs/**'
- 'mkdocs*.yml'
- 'archipy/**'
- 'packages/**'
- 'pyproject.toml'
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@ jobs:
- '!.idea/**'
- '!LICENSE'
- '!mkdocs.yml'
- '!mkdocs-*.yml'
- '!.github/ISSUE_TEMPLATE/**'
- '!.github/workflows/{close-stale-issues,deploy-docs,dependency-review,docs-check,instrumentor-compat,labeler,link-check,pr-merged-issue-comment,publish,ruff-lint,ty-lint}.yml'
- '!.github/labeler.yml'
Expand Down
52 changes: 0 additions & 52 deletions .github/workflows/zensical-evaluation.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ venv.bak/
# Rope project settings
.ropeproject

# mkdocs documentation
# Zensical documentation
/site

# mypy
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ repos:
entry: uv run check-yaml
types:
- yaml
exclude: ^docs/mkdocs
exclude: ^mkdocs
language: system
- id: check-toml
name: check-toml
Expand Down
7 changes: 4 additions & 3 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,16 @@ version: 2
build:
os: ubuntu-22.04
tools:
python: "3.14" # Read the Docs bootstrap. uv supplies Python 3.15 for MkDocs.
python: "3.14" # Read the Docs bootstrap. uv supplies Python 3.15 for Zensical.
commands:
- >-
curl -fsSL https://astral.sh/uv/0.13.9/install.sh -o /tmp/archipy-uv-install.sh &&
UV_UNMANAGED_INSTALL="$HOME/.local/bin" sh /tmp/archipy-uv-install.sh
- '"$HOME/.local/bin/uv" sync --python 3.15 --locked --group docs'
- >-
"$HOME/.local/bin/uv" run --python 3.15 --no-sync mkdocs build
-f docs/mkdocs.yml --site-dir "$READTHEDOCS_OUTPUT/html"
"$HOME/.local/bin/uv" run --python 3.15 --no-sync zensical build
-f mkdocs.yml
- mkdir -p "$READTHEDOCS_OUTPUT/html" && cp -a site/. "$READTHEDOCS_OUTPUT/html/"

search:
ranking:
Expand Down
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Behave in CI (feature groups in `tests.yml`): `make behave FEATURE="features/a.f
- `archipy/` — core package: `models/`, `configs/`, `helpers/`, `adapters/`
- `packages/` — one workspace package per adapter (`redis`, `kafka`, `postgres`, ...), installed through extras
- `features/` — Behave `.feature` files, `steps/`, `test_containers.py`
- `scripts/` — tooling (`behave_parallel.py`); `docs/` — MkDocs site and changelog
- `scripts/` — tooling (`behave_parallel.py`); `docs/` — Zensical site and changelog

## Essential Facts

Expand Down
33 changes: 16 additions & 17 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -231,48 +231,47 @@ check-mr: ## Run pre-commit only on files changed vs BASE (default master), e.g.
$(PRE_COMMIT) run --files $$CHANGED

.PHONY: docs-serve
docs-serve: ## Serve MkDocs documentation locally (balanced mode)
docs-serve: ## Serve Zensical documentation locally (balanced mode)
@echo "${BLUE}Serving documentation...${NC}"
$(UV) run --group docs mkdocs serve -f docs/mkdocs.yml
$(UV) run --group docs zensical serve -f mkdocs.yml

.PHONY: docs-serve-fast
docs-serve-fast: ## Serve MkDocs documentation with fast build (for quick iterations)
docs-serve-fast: ## Serve Zensical documentation with fast build (for quick iterations)
@echo "${BLUE}Serving documentation (fast mode)...${NC}"
$(UV) run --group docs mkdocs serve -f docs/mkdocs-fast.yml
$(UV) run --group docs zensical serve -f mkdocs-fast.yml

.PHONY: docs-serve-no-api
docs-serve-no-api: ## Serve MkDocs documentation without API auto-generation (fastest)
docs-serve-no-api: ## Serve Zensical documentation without API auto-generation (fastest)
@echo "${BLUE}Serving documentation (no API generation)...${NC}"
ENABLE_MKDOCSTRINGS=false $(UV) run --group docs mkdocs serve -f docs/mkdocs.yml
ENABLE_MKDOCSTRINGS=false $(UV) run --group docs zensical serve -f mkdocs.yml

.PHONY: docs-build
docs-build: ## Build MkDocs documentation (balanced mode)
docs-build: ## Build Zensical documentation (balanced mode)
@echo "${BLUE}Building documentation...${NC}"
$(UV) run --group docs mkdocs build -f docs/mkdocs.yml
$(UV) run --group docs zensical build -f mkdocs.yml

.PHONY: docs-check
docs-check: ## Build the docs in strict mode: broken links and API reference errors fail
@echo "${BLUE}Checking documentation...${NC}"
$(UV) run --group docs mkdocs build --strict -f docs/mkdocs.yml -d $$(mktemp -d)
$(UV) run --group docs zensical build --strict -f mkdocs.yml

.PHONY: docs-build-fast
docs-build-fast: ## Build MkDocs documentation with fast config
docs-build-fast: ## Build Zensical documentation with fast config
@echo "${BLUE}Building documentation (fast mode)...${NC}"
$(UV) run --group docs mkdocs build -f docs/mkdocs-fast.yml
$(UV) run --group docs zensical build -f mkdocs-fast.yml

.PHONY: docs-build-full
docs-build-full: ## Build MkDocs documentation with full features (for production)
docs-build-full: ## Build Zensical documentation with full features (for production)
@echo "${BLUE}Building documentation (full mode)...${NC}"
$(UV) run --group docs mkdocs build -f docs/mkdocs-full.yml --clean
$(UV) run --group docs zensical build -f mkdocs-full.yml --clean

.PHONY: docs-time
docs-time: ## Time the documentation build
@echo "${BLUE}Timing documentation build...${NC}"
time $(UV) run --group docs mkdocs build -f docs/mkdocs.yml
time $(UV) run --group docs zensical build -f mkdocs.yml

.PHONY: docs-deploy
docs-deploy: ## Deploy MkDocs to GitHub Pages
@echo "${BLUE}Deploying documentation...${NC}"
$(UV) run --group docs mkdocs gh-deploy --force -f docs/mkdocs-full.yml
docs-deploy: ## Documentation deploys from CI, not locally
@echo "${YELLOW}Documentation is published by .github/workflows/deploy-docs.yml on push to master.${NC}"

.DEFAULT_GOAL := help
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[![Stars](https://img.shields.io/github/stars/SyntaxArc/ArchiPy)](https://github.com/SyntaxArc/ArchiPy)
[![Python](https://img.shields.io/badge/Python-3.14+-blue.svg)](https://www.python.org/downloads/)
[![UV](https://img.shields.io/badge/UV-package%20manager-blue)](https://docs.astral.sh/uv/)
[![Documentation](https://img.shields.io/badge/docs-MkDocs-blue.svg)](https://syntaxarc.github.io/ArchiPy/)
[![Documentation](https://img.shields.io/badge/docs-Zensical-blue.svg)](https://syntaxarc.github.io/ArchiPy/)
[![License](https://img.shields.io/github/license/SyntaxArc/ArchiPy)](https://github.com/SyntaxArc/ArchiPy/blob/master/LICENSE)
[![Maintained](https://img.shields.io/badge/Maintained-yes-brightgreen)](https://github.com/SyntaxArc/ArchiPy)
[![Contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen)](https://github.com/SyntaxArc/ArchiPy/blob/master/CONTRIBUTING.md)
Expand Down Expand Up @@ -180,9 +180,9 @@ Support ArchiPy by checking out our amazing sponsors! [View Sponsors](SPONSORS.m

## 📚 Documentation

ArchiPy's documentation has been migrated from Sphinx to MkDocs for improved readability and organization:
ArchiPy's documentation has been built with Zensical for improved readability and organization:

- **Modern Interface**: Material theme with responsive design
- **Modern Interface**: Responsive theme with responsive design
- **Improved Navigation**: Intuitive organization and search
- **Clearer Examples**: Expanded code samples with explanations
- **API Reference**: Auto-generated from source code docstrings
Expand Down
30 changes: 5 additions & 25 deletions docs/community/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ This section outlines the standards and practices for ArchiPy documentation.

### Documentation Structure

- `mkdocs.yml` - Main configuration file for MkDocs
- `mkdocs.yml` - Main [Zensical](https://zensical.org) configuration file (`mkdocs-fast.yml` and `mkdocs-full.yml` override it)
- `docs/` - Markdown documentation files
- `index.md` - Get Started page
- `api_reference/` - API documentation
Expand Down Expand Up @@ -277,7 +277,7 @@ When including code examples:

### Admonitions

Use Material for MkDocs admonitions to highlight important information:
Use admonitions to highlight important information:

```markdown
!!! note
Expand All @@ -304,33 +304,13 @@ Build the documentation:
make docs-build
```

Deploy to GitHub Pages:
Check the build in strict mode (broken links and API reference errors fail):

```bash
make docs-deploy
make docs-check
```

### Previewing the Zensical Migration

Material for MkDocs reaches end of life on May 5, 2027. The Zensical preview inherits the full MkDocs
configuration and sets paths relative to the repository root. Zensical requires its output to stay
under the configuration directory, so it writes the preview to `site-zensical/`.
[Upstream migration guide](https://zensical.org/docs/compatibility/mkdocs/migration/)

```bash
uv sync --python 3.15 --locked --group docs
uv run --python 3.15 --no-sync --with zensical==0.1.3 zensical build -f zensical-preview.yml
```

The evaluation produced the same 275 page paths as MkDocs and retained the generated FastAPI and Redis
API anchors. Zensical generated its own search index. Check representative navigation, search results,
and existing inbound links in a hosted preview before the switch.

For Pages, publish the generated directory with a static HTML publisher. The preview workflow tests
a `gh-pages` branch using a temporary Git remote. For Read the Docs, copy the directory contents into
`$READTHEDOCS_OUTPUT/html/` from the existing custom build command.
[Zensical publishing guide](https://zensical.org/docs/publish-your-site/) ·
[Read the Docs build customization](https://docs.readthedocs.com/platform/stable/build-customization.html)
The `deploy-docs` workflow publishes to GitHub Pages on every push to `master`.

### Documentation Improvement Guidelines

Expand Down
4 changes: 2 additions & 2 deletions docs/mkdocs-fast.yml → mkdocs-fast.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Fast build configuration for local development
# Use this for quick iterations: mkdocs serve -f docs/mkdocs-fast.yml
# Plugin settings are merged over docs/mkdocs.yml: only the differences are listed here.
# Use this for quick iterations: zensical serve -f mkdocs-fast.yml
# Plugin settings are merged over mkdocs.yml: only the differences are listed here.

INHERIT: ./mkdocs.yml

Expand Down
4 changes: 2 additions & 2 deletions docs/mkdocs-full.yml → mkdocs-full.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Full documentation build with all features
# Use this for production builds: mkdocs build -f docs/mkdocs-full.yml
# Plugin settings are merged over docs/mkdocs.yml: only the differences are listed here.
# Use this for production builds: zensical build -f mkdocs-full.yml
# Plugin settings are merged over mkdocs.yml: only the differences are listed here.

INHERIT: ./mkdocs.yml

Expand Down
Loading
Loading