Skip to content

/wbPublish — Command Hub ​

/wbPublish is the WB-Labs npm publication pipeline. It handles the full publish workflow — version bump validation, pre-publish checks, registry configuration, and topological publish ordering — turning a tested and audited codebase into a publicly installable npm module. It runs only after /wbRelease and refuses otherwise.

The publish pipeline

The publish path, end to end. /wbPublish executes what /wbRelease planned — it is deliberately not the command that decides a version.

🎯 Strategic Position ​

/wbPublish is the final gate in the package distribution pipeline. Every other command ensures the package is correct; /wbPublish ensures it's deliverable. It runs a five-point pre-check automatically (recent release report exists, version matches, workspace:* unpicked, dist/ aligned, version not already on npm) and refuses with specific fixes if any fail. After publish, it demands a /wbRelease --restore — skipping this leaves your dev tree with pinned versions instead of workspace:*, breaking local package linking.

  • After /wbRelease has run — in the same cycle, not days later.
  • Not before — the command refuses without a recent release report.
  • Never for quick tests — use pnpm link or local tarball install instead.

🛠️ Operating Modes ​

ModeTriggerOutput
Publish/wbPublish <pkg>Build, verify, and publish to npm registry
Dry run/wbPublish <pkg> --dry-runShows what would publish without pushing
Prerelease/wbPublish <pkg> --prerelease=<tag>Publish under a tag like @beta or @canary

✅ What a useful publish report contains ​

  1. The release plan it read — topological publish order.
  2. Build verification — build-info.json inspected, version and tier metadata confirmed.
  3. Per-package publish status — success, failure, or skipped with reason.
  4. The restore reminder — --restore must be run after publish.
  5. The next command — typically /wbDeploy <consumer-app>.

🚫 What it cannot do ​

Not thisUse instead
Run tests before publish/wbTest — run before /wbRelease
Create changelogs or bump versions/wbRelease
Deploy an application/wbDeploy
Announce the release/wbBroadcast
Re-publish the same versionnpm publish directly (check registry first)

📚 Reading Order ​

  1. ELI5 — the one-paragraph mental model.
  2. Practical — step-by-step on a real project.
  3. Expert — architecture, edge cases, and when NOT to use.
  4. Examples — annotated transcripts from actual sessions.
  5. Exhaustive simulation · Live demo.
  • wbPublish.md — the command reference this hub orients you around.
  • /wbRelease — must run first; required gate for /wbPublish.
  • /wbDeploy — deploy an application (not an npm package).
  • /wbTest — run tests before the release cycle begins.
  • /wbNext — ranked next action after publish.

Quick Reference ​

bash
/wbPublish <pkg>              # build + publish to npm
/wbPublish <pkg> --dry-run    # show what would publish, don't push
/wbPublish <pkg> --prerelease=beta  # publish under a prerelease tag


← Home · Commands · Install | wb-flow on npm · flow.wbc-ui.com · wi-bg.com