Dashboard › craft › Distillation
328e4f71-5a95-4fac-8e0f-48ef7898b0de["lore_tm_v1_2X2zOxRO0EPXAPRWkbdoTDoKAhB6e2h2ZEb_wdafVow"]
Date: Aug 27, 2026
src/commands/publish.ts imports workspace-aware configuration utilities getConfiguration, getActiveWorkspace, and expandWorkspaceTargets; release-command environment builder buildReleaseCommandEnv from src/utils/releaseCommandEnv; and publish-state path generator getPublishStatePath from src/utils/publishState.src/commands/publish.ts defines publish command ['publish NEW-VERSION'], aliases ['pp', 'publish'], description 🛫 Publish artifacts, and default post-release script path scripts/post-release.sh.src/commands/publish.ts:builder computes allowed --target choices from workspace-resolved getConfiguration().targets; it retains only configured targets with a name that appears in getAllTargetNames() and maps them through BaseTarget.getId. If configuration cannot resolve at parse time—such as missing/invalid config or workspace config without selection during shell completion—it falls back to all known target names rather than aborting parsing.NEW-VERSION is a required string version via .demandOption('new-version', 'Please specify the version to publish') and validates it with .check(checkVersion).--target/-t is a string constrained to workspace-derived allowed targets plus SpecialTarget.All and SpecialTarget.None; it defaults to SpecialTarget.All and supports publishing to a selected target.--rev/-r (string source git SHA or tag when not publishing the release-branch head), --merge-target/-m (string merge branch, defaulting to GitHub’s default branch when omitted), and --remote (string, defaults to origin).--no-merge (do not merge release branch after publishing), --keep-branch (do not remove release branch after merge), --keep-downloads (keep downloaded files), --no-status-check (skip build-status check), and --no-git-checks (ignore local changes and unsynchronized remotes).PublishOptions declares remote: string, optional rev, optional mergeTarget, optional target: string | string[], required newVersion: string, and required booleans noMerge, keepDownloads, noStatusCheck, keepBranch, and noGitChecks; PublishState stores published as a target-ID-to-boolean map.