Skip to content

q2 create: blog scaffold (website:blog) + listing Q1-parity fixes - #434

Merged
cscheid merged 4 commits into
mainfrom
feature/bd-r1by4u2a-blog-scaffold
Jul 30, 2026
Merged

q2 create: blog scaffold (website:blog) + listing Q1-parity fixes#434
cscheid merged 4 commits into
mainfrom
feature/bd-r1by4u2a-blog-scaffold

Conversation

@cscheid

@cscheid cscheid commented Jul 29, 2026

Copy link
Copy Markdown
Member

Implements bd-r1by4u2a: the blog project choice (website:blog) in quarto-project-create, flipped to implemented — picked up by the CLI (positional, --json directive, interactive) and the hub-client WASM path automatically. First real user of the ScaffoldContent::Binary path (the two post JPEGs, one-time copies from Q1's resources).

Plan + full e2e transcript: claude-notes/plans/2026-07-29-blog-scaffold.md.

Listing fixes (bd-2qjnd, bd-9arwdicv, bd-qv2lsab0)

Rendering a Q1-shaped blog before writing scaffold code surfaced three gaps in the listing machinery, each fixed TDD-first:

  • sort: "date desc" — front-matter strings arriving as PandocInlines fell through parse_sort to Q-12-3 with an empty sort; now routed via as_plain_text like parse_contents (bd-2qjnd).
  • contents: posts — a bare directory entry (Q1's canonical blog shape) matched zero files; new dir-aware glob_match_path_or_dir used by both the render-time matcher and the dep-graph edge builder (bd-9arwdicv).
  • Front-matter image: — emitted verbatim into the host page (404) and never copied to _site/; now rebased document→project-relative at hydration, host-relativized at emission, and copied via ResourceCopyIntent. Also the shape the RSS feed builder expects (bd-qv2lsab0).

Scaffold

Q1-familiar 9-file set; post dates stamped today / today−3d via a new time dep (wasm-bindgen clock on wasm32; with_today pins tests). Deliberate deviations, documented in the plan: no brand theme marker (Q-14-1), no editor:, no freeze: (no Q2 freeze, bd-mx5x609r), no about: jolla block / profile.jpg (no Q2 about pages, bd-5xmy5lle).

Known caveat (deliberate): listing cards render unstyled until quarto-listing.scss is vendored (bd-57y4, follow-up in progress).

Verification

  • cargo nextest run --workspace: 10790/10790
  • full cargo xtask verify: all steps passed
  • e2e through the real binary: q2 create project blogq2 render warning-free; listing date-desc with working images, RSS feed, category chips, banner title blocks; JSON directive + dry-run paths exercised

🤖 Generated with Claude Code

cscheid and others added 4 commits July 29, 2026 12:18
…d-9arwdicv, bd-qv2lsab0)

Three listing fixes discovered while scoping the blog scaffold
(bd-r1by4u2a), each TDD'd:

- parse_sort: route string-shaped values through as_plain_text so
  front-matter strings arriving as PandocInlines (e.g. sort: "date
  desc") parse instead of emitting Q-12-3 with an empty sort
  (bd-2qjnd). Drop the now-unneeded workaround in docs/errors.
- contents: a bare directory entry (contents: posts — Q1's canonical
  blog shape) now matches everything under the directory via the new
  dir-aware glob_match_path_or_dir, used by both the render-time
  matcher and the dep-graph edge builder (bd-9arwdicv).
- front-matter image: rebased document-relative → project-relative at
  hydration, host-relativized at emission, and registered as a
  ResourceCopyIntent so the file reaches the output tree; also makes
  the value the shape the RSS feed builder expects (bd-qv2lsab0).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Port Quarto 1's blog template to quarto-project-create and flip the
'blog' choice to implemented — the CLI (positional, JSON directive,
interactive) and the hub-client WASM path pick it up automatically.

Scaffold: Q1-familiar 9-file set — _quarto.yml (website.title,
description, RSS site-url placeholder, navbar with github/bluesky
icon items, cosmo), listing index.qmd with Q1's canonical config
(contents: posts, sort: "date desc", feed: true), posts/_metadata.yml
(banner title blocks; Q1's freeze: dropped — no Q2 freeze,
bd-mx5x609r), two starter posts, about.qmd (Q1's about: jolla block
dropped — no Q2 about pages, bd-5xmy5lle), styles.css. The two post
JPEGs are the first users of the ScaffoldContent::Binary path and are
one-time copies from Q1's resources.

Post dates stamp today / today-minus-3-days via a new time dep
(wasm-bindgen clock on wasm32); CreateFromChoiceOptions::with_today
pins the date in tests. The scaffold sweep test's per-template
invariant is now 'interpolates at least one variable' since the post
templates carry $first/second-post-date$ rather than $title$.

Tests: quarto-project-create 31/31 (new blog file-set + date tests,
Windows-safe path comparisons), quarto CLI create suite 30/30 (blog
e2e incl. byte-identical binary round-trip; unimplemented-choice
tests repointed at manuscript), interactive prompt tests updated for
the three-choice registry, hub-client projectCreate.wasm.test.ts 7/7
against freshly built WASM. Full workspace: 10790/10790.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…-r1by4u2a)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@posit-snyk-bot

posit-snyk-bot commented Jul 29, 2026

Copy link
Copy Markdown

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@cscheid
cscheid merged commit e86a927 into main Jul 30, 2026
8 checks passed
@cscheid
cscheid deleted the feature/bd-r1by4u2a-blog-scaffold branch July 30, 2026 00: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.

2 participants