Skip to content

[V2:09] Run Zola With Workspace Theme#23

Open
ritorhymes wants to merge 6 commits into
eips-wg:masterfrom
ritovision:v2/09-local-zola-theme-runner
Open

[V2:09] Run Zola With Workspace Theme#23
ritorhymes wants to merge 6 commits into
eips-wg:masterfrom
ritovision:v2/09-local-zola-theme-runner

Conversation

@ritorhymes

@ritorhymes ritorhymes commented May 5, 2026

Copy link
Copy Markdown
Contributor

Part of V2: Multi-repo local build system.

Summary

This PR replaces the remote theme fetch/cache path with the workspace-local theme/ checkout used by theme-dependent build, check, serve, and editorial workflows. The local theme is mounted into the prepared repository at themes/eips-theme before Zola runs, while Zola and eipw configuration resolve from that checkout.

The active repository remains local by default. --remote-siblings may change sibling-source selection, but it does not restore remote theme fetching: theme-dependent workflows still use the editable local workspace theme. Commands that do not require Zola or eipw theme configuration, including changed and clean, remain independent from theme resolution.

  • Remove the remote theme cache module and its directories / sha3 dependencies.
  • Resolve the workspace-local theme source for Zola-backed and editorial workflows.
  • Require an existing local theme/ checkout where Zola or eipw configuration is needed.
  • Mount the local theme at repo/themes/eips-theme before invoking Zola.
  • Load Zola configuration from the mounted theme and eipw configuration from the local theme checkout.
  • Keep commands such as changed and clean independent from theme resolution.
  • Add execution and Zola tests for missing theme setup, mounted theme paths, replacement of stale mounts, and external-link handling.

Review Notes

This is the runtime theme switch. Before this PR, runtime code could fetch and cache a remote theme revision. After it, every theme-dependent workflow uses the workspace-local theme established by V2:06 and validated by V2:07.

The local theme is a development source. It remains editable regardless of whether an execution uses the default active local source, --clean, or --remote-siblings.

ResolvedExecution carries the local theme location for callers that require it. Build, check, serve, and editorial commands require a theme; commands that do not need Zola or eipw configuration do not.

Remote theme support is intentionally removed. --remote-siblings changes only declared sibling-source selection; it does not change the theme source or permit a fetched theme.

Zola receives the theme through a mounted path in the disposable prepared repository: repo/themes/eips-theme. The Zola config path derives from that mounted theme so relative theme assumptions match normal Zola project layout. eipw reads config/eipw.toml directly from the local theme checkout.

This PR does not add the prepared runtime pipeline itself. V2:10 moves build and check preparation into the dedicated pipeline module while retaining this local-theme model.

Verification

  • Review src/execution.rs for local-theme resolution, missing-theme errors, and applicability to build, check, serve, and editorial commands.
  • Review src/main.rs and src/lint.rs for eipw configuration loading from the local theme rather than the removed cache.
  • Review src/zola.rs for local-theme mounting, mounted config-path construction, and Zola build/check/serve invocation.
  • Review src/layout.rs for output, mounted-theme, and theme-config path helpers.
  • Review Cargo.toml, Cargo.lock, src/cache.rs, and src/git.rs for removal of the remote theme-cache path.
  • Review tests for missing local-theme errors, mounted theme behavior, stale mount replacement, and external-link behavior.

@ritorhymes ritorhymes changed the title Run Zola With Workspace Theme [V2:09] Run Zola With Workspace Theme May 5, 2026
@ritorhymes ritorhymes force-pushed the v2/09-local-zola-theme-runner branch 3 times, most recently from 77b48a8 to bf32bca Compare May 9, 2026 20:10
@ritorhymes ritorhymes force-pushed the v2/09-local-zola-theme-runner branch from bf32bca to f915e5e Compare May 26, 2026 01:02
Add workspace-local `.build-eips.toml` loading and starter configuration. Introduce `config::ActiveRepo` to load the selected checkout’s `Build.toml`, validate explicit `-C` roots, and expose active repository context to later commands. Keep source materialization, initialization, and diagnostics in their owning later branches.
Add clean and dirty source materialization for the active repository and sibling content. Use `config::RepositoryUse` throughout the runtime path, preserve tracked working-tree materialization and `index_path`, and reject dirty active manifests in clean modes. Build, check, and serve prepare sources without fetching the active upstream; `changed` retains upstream fetching for comparison.
Add workspace initialization from the selected active `Build.toml`. Clone missing sibling repositories from declared locations and initialize a missing theme checkout from the manifest repository and pin. Preserve existing usable checkouts and fail without deleting unusable paths. Write `.build-eips.toml` only when absent and generate `WORKSPACE.md` for the initialized workspace.
Add `build-eips doctor` for validating workspace configuration, active `Build.toml`, managed sibling repositories, the local theme checkout, and required tools. Report ok/warn/fail diagnostics; invalid active manifests and unusable theme configuration fail, while expected sibling and theme-pin conditions can warn. Keep diagnostics read-only and leave execution and runtime behavior to later branches.
Resolve build, check, and serve source policy around local active sources, clean mode, remote siblings, build roots, and base URL precedence. Keep `--clean` and `--remote-siblings` as source controls and limit `--only` to supported local dirty modes. Route runtime commands through one resolved execution policy.
Run Zola with the editable `workspace/theme` checkout. Materialize tracked local theme files into prepared `themes/eips-theme`, load Zola and eipw configuration from that local checkout, and keep runtime commands independent of manifest network access.
@ritorhymes ritorhymes force-pushed the v2/09-local-zola-theme-runner branch from f915e5e to 8a5807b Compare June 21, 2026 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant