Skip to main content

Publishing (Phase 4)

Goal: prepare content in Markdown, control the publishing state from the terminal, and use WordPress only to review the rendered page.

The rule​

ConcernOwner
Draft creation/update and status read-backTerminal (SCS)
Pending, scheduled, published stateWordPress approved workflow
Visual review of the rendered postWordPress
Images, callouts, links, TOC, diagrams, code blocksMarkdown
important

Do not use the WordPress editor to add routine content. If a block renders badly, fix the Markdown or the converter. WordPress is a review window, not an editing surface.

Status flow​

SCS keyword statusWordPress post_statusMeaning
Writing / EditingdraftDraft being written
QAdraftDraft created, review pending
ScheduledfutureReview approved, schedule set
PublishedpublishLive
TrackingpublishGSC data being collected

Published is the only state that can place a URL in the site's XML sitemap. Drafts and scheduled posts are excluded by the SEO plugin, and SCS does not generate sitemap XML. See XML Sitemaps.

Commands​

# Build and inspect the payload locally; no WordPress call
scs wp draft --workspace bs --pid FS-0001 --dry-run

# Create or update a draft (keyed by scs_pid)
scs wp draft --workspace bs --pid FS-0001

# Publish live now (requires an approved QA gate)
scs wp publish now --workspace bs --pid FS-0001

# Schedule a future publish date (requires an approved QA gate)
scs wp publish 2026/12/31 --workspace bs --pid FS-0001

# Apply a desired state stored in publishing.csv / front matter
scs wp publish --workspace bs --pid FS-0001

# Read the current WordPress state back into publishing.csv
scs wp status --workspace bs --pid FS-0001

All publish commands also accept a registered article Markdown path instead of --workspace and --pid.

note

scs wp draft creates or updates a WordPress draft. scs wp publish now and scs wp publish <date> require an approved QA snapshot and never convert a live post back to draft. scs wp status reads the current WordPress status, permalink, and publish date back into publishing.csv. Desired state can also be stored in publishing.csv (wp_status, publish_date) or the article front matter and applied with scs wp publish <article.md>.

What the publish payload contains​

SourceWritten to WordPress
Article titlepost_title
Article half (after <!-- scs:article -->)post_content as Gutenberg blocks
publishing.slugpost_name
publishing.wp_author_idpost author
publishing.wp_category, wp_tagcategory and tags
publishing.wp_content_formatcontent_format taxonomy
publishing.wp_authority_topicwebboulder_authority_topic
publishing.meta_title, meta_descriptionSEOPress metadata
clusters.kc_typeACF content_type
keywords.keywordACF primary_keyword
clusters.entity_coverageACF semantic_tags
scs_pidpost meta idempotency key

The article front matter is not sent to WordPress. It is the writer-facing view of the CSV metadata.

Prepare these in Markdown​

  • Images — reference featured and inline images; keep the files at the expected path so the automation can upload them.
  • Admonitions — use :::tip, :::note, :::warning.
  • Internal links — use [anchor](pid:FS-0003); SCS resolves the PID to the published permalink.
  • Table of contents — generated on the site by the TOC plugin.
  • Mermaid diagrams — fenced mermaid blocks; rendered by the site plugin.
  • Code blocks — fenced code; styled by the site plugin.

What you do in WordPress​

  • Visual review — inspect images, callouts, links, TOC, diagrams, and code.
  • Review gate — set status, reviewer, date, scope, and checklist.
  • Nothing else — do not publish from the editor; change state from the terminal.

Taxonomy​

  • Categories map to wp_category and must exist in WordPress.
  • Tags come from wp_tag (comma-separated).
  • Pillar pages are WordPress Pages; regular content is Posts.
  • Content format comes from wp_content_format, not from ACF content_type.
tip

Run scs publish --dry-run before the first write to a new site. ACF and taxonomy mappings differ between sites.

Next: Publish Bridge, QA Gate, WordPress Contract, Plugin Stack, or XML Sitemaps.