Skip to content

Simplify Documentation Stack: Remove mkdocstrings and gen-files #138

@Kilo59

Description

@Kilo59

As the project evolves, we should simplify our documentation stack to remove the maintenance burden of auto-generated API docs and prepare for a future Zensical migration. ruff-sync is a CLI tool, and the auto-generated API reference (gen-files + mkdocstrings) is low value compared to hand-authored documentation that focuses on the CLI interface and core integration points.

Tasks

  1. Remove Dependencies
    Remove mkdocstrings and mkdocs-gen-files from pyproject.toml under [dependency-groups.docs].

  2. Delete Generation Scripts
    Delete the file docs/gen_ref_pages.py. This script is currently used by gen-files to discover and generate API pages.

  3. Update mkdocs.yml Plugins
    Remove the gen-files and mkdocstrings plugins from the plugins: block in mkdocs.yml.

# Remove these:
- gen-files:
    scripts:
      - docs/gen_ref_pages.py
- mkdocstrings:
    handlers:
      python:
        paths: [src]
        # ... (options)
  1. Create Hand-Authored API Reference (docs/reference/api.md)
    Create a new file docs/reference/api.md that provides a high-level summary of the ruff-sync CLI and core library. It should include:
  • CLI Commands: A summary of pull, check, and init commands (use ruff-sync --help as a guide).
  • Core Result Types: A brief overview of the Config (TypedDict) and FetchResult (NamedTuple) from src/ruff_sync/core.py.
  • Main Entry Point: Mention that the core logic resides in ruff_sync.core.sync or the cli.main function.
  1. Update Navigation
    In mkdocs.yml, update the nav: block so that "API Reference" points directly to the new api.md file:
nav:
  - ...
  - API Reference: reference/api.md

Validation

  • Run uv run mkdocs build and ensure the site builds without errors and the new API Reference page is correctly rendered.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions