publishing-kit
A Codex- and Claude Code-compatible skill and toolchain for publishing a technical
article to AWS Builder Center, dev.to, Medium and Substack, and announcing it on
LinkedIn.
Four destinations, four different artifacts — not four copies of one. They
disagree about tables, about code blocks, and about cover images, and every
disagreement fails silently. You get a plausible-looking file that the
destination quietly mangles, and you find out after publishing.
This packages the workarounds, the generators, and two checks that fail loudly
instead.
Install in Codex
codex plugin marketplace add xbill9/publishing-kit
codex plugin add publishing@publishing-kit
For a manual install, copy skills/publishing/ into
${CODEX_HOME:-~/.codex}/skills/publishing/.
Invoke it as $publishing, or describe a technical-article publishing task and
let Codex select it automatically. Browser-only steps require a Codex environment
with browser automation; the generators, checks, and dev.to API workflow run from
the shell.
Antigravity (agy)
Install directly via the agy CLI:
agy plugin install /path/to/publishing-kit
Or copy skills/publishing/ into your workspace at .agents/skills/publishing/ (or global ~/.gemini/config/skills/publishing/).
Claude Code
The existing Claude plugin remains supported:
/plugin marketplace add xbill9/publishing-kit
/plugin install publishing
Or copy skills/publishing/ into ~/.claude/skills/.
Requirements
The checks and API workflow use Python 3 and the standard library. Cover and
Medium image generation additionally require
Pillow and pandoc. Browser-only publishing
steps require a signed-in browser automation environment.
What it does
Fails the build when a cover image is missing. Every article needs one and
nothing errors locally without it — dev.to only fetches the cover_image: URL at
render time, so a missing or uncommitted file surfaces as a broken image on a
published post.
Converts tables and code for Medium. Medium's importer strips markdown tables
entirely and flattens <pre> to a single line. make-medium.py renders them to
PNG at 2x and emits a self-contained paste variant and a hosted import variant.
Substack has no tables either, so the same hosted file feeds it, adapted in the
page by scripts/browser/substack-editor.js (references/substack.md). A LinkedIn
article takes the same file through scripts/browser/linkedin-article.js, which
adapts it on 127.0.0.1 because the editor's page cannot parse HTML
(references/linkedin-article.md).
Traces every factual claim to an artifact. check-facts.py extracts prices,
measurements, versions and cloud identifiers, then reports which appear in no
evidence file you supplied. It cannot tell you a number is true — it tells you
which numbers you are asserting from memory.
Scripts
| Script | Purpose |
|---|
preflight.py | Start here. Runs every check for an article with one exit code. --live fetches every published URL and compares bytes. |
make-builder.py | Derives the Builder Center version from the dev.to source: front matter, emoji and any AWS disclaimer out (Builder Center adds its own), title/subtitle in. Checks table width. |
check-links.py | Fetches every cover and Medium image URL and compares the served bytes to disk, and fetches every article link the way Builder Center's publish gate does (no cookies): FAIL on broken links and on links that only resolve through a sign-in hop. The only check that sees what a reader sees. |
check-article.py | Pre-flight. Cover exists, is referenced, is committed, right geometry; published: false; front matter complete; Medium artifacts resolve to this article's directory. Exits non-zero. |
check-prose.py | Prose lint. Fails on the author's banned phrasing — narrating the work, "X is not Y" contrast lines, sincerity filler, internal jargon — from the prose-lint block in references/house-style.md. Code blocks and inline code are skipped. Run by preflight.py. |
check-facts.py | Fact-tracing against evidence files. Exits non-zero on untraced claims. .factsignore records deliberate exemptions with reasons. A claim measured earlier and deliberately not re-run may cite a dated ## LOG row in the article's ledger (--ledger, default CLAIMS.md beside it); those print as LOG <date> and do not fail the run. The ledger may not sit inside --evidence. Reads scientific notation (4.2e-9, 4.2 × 10⁻⁹). A JSON object with paper_value, computed and verdict is an audit record: a claim equal to the paper value of a MISMATCH or NOT CHECKABLE record fails as DISPUTED unless a ## DISPUTED ledger row contains it. |
make-medium.py | Tables and diagrams to PNG, emits -embed.html (paste) and -hosted.html (import). |