Files
openclaw/scripts/lib/npm-publish-plan.d.mts
Dallin Romney 74cc99f2d1 fix(release): publish extended-stable Docker channels safely (#112494)
* fix(release): isolate extended-stable Docker aliases

* fix(release): harden Docker channel promotion

* docs(release): pin Docker policy into tagged tree

* refactor(release): isolate Docker channel promotion

* fix(release): queue Docker publications

* fix(release): harden docker channel promotion

* docs(release): tighten extended-stable guidance

* fix(release): promote Docker aliases after verification

* chore(release): format maintainer instructions

* refactor(release): separate release version policy

* docs(release): clarify extended-stable gateway scope

* fix(release): harden Docker channel promotion
2026-07-23 10:03:11 +09:00

40 lines
1.4 KiB
TypeScript

export type NpmPublishPlan = {
channel: "stable" | "alpha" | "beta";
publishTag: "latest" | "alpha" | "beta" | "extended-stable";
mirrorDistTags: Array<"latest" | "alpha" | "beta">;
};
export type PublishedNpmVersionRoute = "npm-readback" | "npm-mirror" | "npm-tag-repair";
export type NpmRegistryPackumentResult = {
status: number;
ok: boolean;
packument: unknown;
};
export function fetchNpmRegistryPackumentWithRetry(params: {
packageName: string;
packageUrl: string;
attempts?: number;
timeoutMs?: number;
fetchImpl?: (input: string, init: RequestInit) => Promise<Response>;
sleep?: (delayMs: number) => Promise<void>;
createSignal?: (timeoutMs: number) => AbortSignal;
}): Promise<NpmRegistryPackumentResult>;
export function resolveNpmPublishPlan(
version: string,
currentBetaVersion?: string | null,
publishTagOverride?: string | null,
): NpmPublishPlan;
export function resolvePublishedNpmVersionRoute(params: {
packageVersion: string;
publishPlan: NpmPublishPlan;
distTags: Record<string, unknown>;
}): PublishedNpmVersionRoute;
export function resolveNpmDistTagMirrorAuth(params?: {
nodeAuthToken?: string | null;
npmToken?: string | null;
}): { hasAuth: boolean; source: "node-auth-token" | "npm-token" | "none" };
export function shouldRequireNpmDistTagMirrorAuth(params: {
mode: "--dry-run" | "--publish";
mirrorDistTags: readonly string[];
hasAuth: boolean;
}): boolean;