Transmission #055: PDD scaffolding for blog AdSense banner
Started Prompt-Driven Development planning for adding a Google AdSense banner to the Hugo blog. Created .agents/planning/2026-04-25-blog-adsense-banner/ with rough-idea.md, idea-honing.md, and research/, design/, implementation/ placeholders so requirements, research, design, and an implementation plan can proceed in order.
PDD requirements (AdSense)
Q1: Site-wide bottom banner on every HTML page; no other placements for now. Recorded in idea-honing.md.
Q2: Ads always in the built HTML—no dev/prod toggle. Recorded in idea-honing.md.
Q3: Prefer simplest standard AdSense embed for v1 (no CMP build); revisit if traffic or policy needs change. Recorded in idea-honing.md.
Q4: Ad lives in the footer / bottom strip; no strict above-vs-below footer. Recorded in idea-honing.md.
Q5: Onboarding head loader for ca-pub-1954004982198713. Recorded in idea-honing.md.
Q6: Auto ads (simplest); Google may place beyond a single footer strip. v1 plan: head script + enable Auto ads in AdSense (no required manual data-ad-slot). Recorded in idea-honing.md.
Q7: User marked requirements clarification complete; consolidated table in idea-honing.md.
Detailed design (AdSense)
Authored .agents/planning/2026-04-25-blog-adsense-banner/design/detailed-design.md: single head.html injection via existing baseof, hugo.toml param for ca-pub client string, Auto ads + console operator steps, nginx/Hugo CSP note for later, testing via build + grep/view-source, and appendices (alternatives, constraints). Ready for implementation plan when approved.
Implementation plan (AdSense)
Added .agents/planning/2026-04-25-blog-adsense-banner/implementation/plan.md: checklist + Step 1 hugo.toml + operator TOML comments, Step 2 head.html loader with build-time guard, Step 3 Docker parity and deploy/Auto ads handoff. Each step lists tests, integration, and demo per PDD.
PDD wrap-up
Added summary.md listing artifacts, short design/plan recap, next steps, and refinement ideas. PDD path for this idea is complete until you want to revise requirements or execute the plan in the codebase.
Implementation (live in repo)
blog/hugo.toml: [params.adsense] with client = "ca-pub-1954004982198713" and comments pointing operators to Auto ads after deploy. blog/layouts/_partials/head.html: async adsbygoogle.js in <head> from that param; build errors if client is unset. Verified hugo --minify, rg across public/**/*.html, and docker build (linux/amd64) for blog/. Planning checklist in implementation/plan.md marked complete.
You still do in AdSense: enable Auto ads and finish site review when Google is ready—nothing further required in Git for the loader path.
AdSense snippet parity
Adjusted head.html so the built <script> uses the same line break as Google’s onboarding snippet (src line + crossorigin line). Output is still driven by hugo.toml params.adsense.client so the ca-pub-… value is not duplicated; rendered HTML matches Google’s tag aside from Hugo’s optional generator meta elsewhere in <head>.