初始化项目版本

This commit is contained in:
Axhub Make
2026-07-29 16:04:39 +08:00
commit 4305a1082b
2629 changed files with 760590 additions and 0 deletions

26
scripts/utils/serverInfo.d.ts vendored Normal file
View File

@@ -0,0 +1,26 @@
export type AxhubServerRole = 'runtime' | 'admin';
export interface AxhubServerInfo {
pid: number;
port: number;
host: string;
origin: string;
projectRoot: string;
startedAt: string;
}
export interface ServerInfoPathOptions {
homeDir?: string;
}
export function readServerInfo(projectRoot: string, role: AxhubServerRole, options?: ServerInfoPathOptions): AxhubServerInfo | null;
export function getAdminServerInfoPath(projectRoot?: string, options?: ServerInfoPathOptions): string;
export function getRuntimeServerInfoPath(projectRoot: string): string;
export function writeServerInfo(
projectRoot: string,
role: AxhubServerRole,
info: AxhubServerInfo,
options?: ServerInfoPathOptions,
): AxhubServerInfo;
export function fetchHealth(origin: string, timeoutMs?: number): Promise<unknown | null>;
export function normalizeHealthServerInfo(data: unknown): AxhubServerInfo | null;