Skip to main content

Transparent Vite + pnpm orchestration for Sphinx theme asset pipelines

Project description

gp-sphinx-vite

Transparent Vite + pnpm orchestration for Sphinx theme asset pipelines.

A Sphinx extension that spawns pnpm exec vite build --watch from builder-inited so theme authors iterating templates and SCSS get fresh furo.css / furo.js on disk without remembering a separate vite build command. The extension is a no-op in production (when sphinx-build runs without the autobuild driver), so wheels published to PyPI never carry a Node runtime requirement.

Status

Skeleton — only setup() and config-value registration are wired up. Subprocess management (ViteProcess), the asyncio↔threading bridge, and the actual spawn/teardown lifecycle (with signal handling and idempotent re-spawn for sphinx-autobuild) land in subsequent commits.

Usage (eventual)

# conf.py
extensions = ["gp_sphinx_vite"]

# Optional. Defaults to "auto": dev iff SPHINX_AUTOBUILD env var is set
# or sys.argv[0] ends with "sphinx-autobuild"; prod (no-op) otherwise.
gp_sphinx_vite_mode = "auto"

# Optional. Path to the directory containing package.json + vite.config.ts.
# Defaults to <theme directory>/web (resolved relative to the active theme).
gp_sphinx_vite_root = None

Config

Name Type Default
gp_sphinx_vite_mode Literal["auto", "dev", "prod"] "auto"
gp_sphinx_vite_root str | None None (auto-detect)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gp_sphinx_vite-0.0.1a16.dev2.tar.gz (14.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gp_sphinx_vite-0.0.1a16.dev2-py3-none-any.whl (15.4 kB view details)

Uploaded Python 3

File details

Details for the file gp_sphinx_vite-0.0.1a16.dev2.tar.gz.

File metadata

  • Download URL: gp_sphinx_vite-0.0.1a16.dev2.tar.gz
  • Upload date:
  • Size: 14.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for gp_sphinx_vite-0.0.1a16.dev2.tar.gz
Algorithm Hash digest
SHA256 524c1d5ad9800bef31d8f2ffb9778dde9a2934e218278a50a3cfc68d023b59da
MD5 6cd565762198005629fc116601bc64b5
BLAKE2b-256 3c5ae1860dfbdd80c4e8511ca3b7514dff37ab2305f862fad7a18127b5abefe0

See more details on using hashes here.

Provenance

The following attestation bundles were made for gp_sphinx_vite-0.0.1a16.dev2.tar.gz:

Publisher: release.yml on git-pull/gp-sphinx

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gp_sphinx_vite-0.0.1a16.dev2-py3-none-any.whl.

File metadata

File hashes

Hashes for gp_sphinx_vite-0.0.1a16.dev2-py3-none-any.whl
Algorithm Hash digest
SHA256 44a494f5cf4cb8b314bae456ea7184046ee185a03f61b860506bd3990a3f63db
MD5 47e00be257bc865ef0f4017e1066d9f4
BLAKE2b-256 89981c1eb433e2cf5453ee157183090b4d2be97ca096664a68039fd9db5cf8cb

See more details on using hashes here.

Provenance

The following attestation bundles were made for gp_sphinx_vite-0.0.1a16.dev2-py3-none-any.whl:

Publisher: release.yml on git-pull/gp-sphinx

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page