builder.io 1.9.15 → 1.9.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli/index.cjs +251 -282
- package/cli/index.cjs.map +4 -4
- package/core/index.cjs +1 -1
- package/core/index.mjs +1 -1
- package/node/index.cjs +1 -1
- package/node/index.mjs +1 -1
- package/package.json +1 -1
- package/server/index.cjs +49 -49
- package/server/index.mjs +50 -50
- package/types/cli/codegen.d.ts +3 -2
- package/types/cli/launch/InitStateMachine.d.ts +1 -0
- package/types/cli/launch/dev-server-orchestrator.d.ts +2 -3
- package/types/cli/launch/server.d.ts +1 -0
- package/types/cli/repo-indexing/repo-indexing-utils.d.ts +1 -0
- package/types/cli/utils/git.d.ts +2 -2
- package/types/tsconfig.tsbuildinfo +1 -1
package/types/cli/codegen.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ import type { CodegenFeedback, CodeGenToolMap, CodegenTurn, CommitMode, CustomIn
|
|
|
4
4
|
import prettier from "prettier";
|
|
5
5
|
import { type FusionContext } from "./code-tools";
|
|
6
6
|
import EventEmitter from "node:events";
|
|
7
|
+
import { type RunGitOptions } from "./utils/git";
|
|
7
8
|
export interface SessionContext {
|
|
8
9
|
sessionId: string;
|
|
9
10
|
turns: CodegenTurn[];
|
|
@@ -73,7 +74,7 @@ export declare class CodeGenSession {
|
|
|
73
74
|
details: string;
|
|
74
75
|
}>;
|
|
75
76
|
archiveProject(): Promise<string>;
|
|
76
|
-
isIdle():
|
|
77
|
+
isIdle(): boolean;
|
|
77
78
|
needsBackup(): Promise<boolean>;
|
|
78
79
|
uploadBackup(): Promise<import("./backup").BackupGitRepoResultValid | import("./backup").BackupGitRepoResultInvalid | {
|
|
79
80
|
success: boolean;
|
|
@@ -112,7 +113,7 @@ export declare class CodeGenSession {
|
|
|
112
113
|
* Get the AI branch name
|
|
113
114
|
*/
|
|
114
115
|
getAiBranch(): string | undefined;
|
|
115
|
-
git(args: string[],
|
|
116
|
+
git(args: string[], opts?: string | RunGitOptions): Promise<string>;
|
|
116
117
|
/**
|
|
117
118
|
* Helper to run git commands
|
|
118
119
|
*/
|
|
@@ -39,6 +39,7 @@ export declare class InitStateMachine {
|
|
|
39
39
|
private isGitConfigured;
|
|
40
40
|
private getGitRemoteUrl;
|
|
41
41
|
private sanitizeGitRemoteUrl;
|
|
42
|
+
private cleanupLockFiles;
|
|
42
43
|
validateGitRepo(repoPath: string): Promise<void>;
|
|
43
44
|
/**
|
|
44
45
|
* If a backup is available, perform a backup recovery (and throw if it fails and cannot be recovered from).
|
|
@@ -2,8 +2,7 @@ import type { DevToolsSys } from "@builder.io/dev-tools/core";
|
|
|
2
2
|
import { type RequestHandler as ProxyRequestHandler } from "http-proxy-middleware";
|
|
3
3
|
import type { DevCommandState, HttpServerState } from "$/ai-utils";
|
|
4
4
|
import EventEmitter from "events";
|
|
5
|
-
import {
|
|
6
|
-
import type { Readable } from "node:stream";
|
|
5
|
+
import { ChildProcess } from "node:child_process";
|
|
7
6
|
import type { FusionConfig, SetupCommandState } from "$/ai-utils";
|
|
8
7
|
export type DevServerState = Exclude<SetupCommandState | DevCommandState, "installed" | "starting">;
|
|
9
8
|
export interface SetupCommandResult {
|
|
@@ -58,4 +57,4 @@ export interface DevServerOrchestrator {
|
|
|
58
57
|
}
|
|
59
58
|
export declare function devServerOrchestrator(sys: DevToolsSys, fusionConfig: FusionConfig, initialSetupState: "installed" | "not-installed" | "install-failed"): Promise<DevServerOrchestrator>;
|
|
60
59
|
export declare const checkPortsListenedByPid: (pid: number) => number[];
|
|
61
|
-
export declare function killProcess(sys: DevToolsSys, proc:
|
|
60
|
+
export declare function killProcess(sys: DevToolsSys, proc: ChildProcess | undefined, abortSignal?: AbortSignal, timeout?: number): Promise<boolean>;
|
|
@@ -9,6 +9,7 @@ export declare const NON_AUTHENTICATED_ENDPOINTS: {
|
|
|
9
9
|
readonly STATUS: "/status";
|
|
10
10
|
readonly PROXY_STATUS: "/proxy-status";
|
|
11
11
|
readonly STATUS_V2: "/status-v2";
|
|
12
|
+
readonly INIT_LOGS: "/init-logs";
|
|
12
13
|
};
|
|
13
14
|
export declare const configureServer: ({ app, validBuilderPrivateKey, authenticateProxy, isLocal, sharedState, }: {
|
|
14
15
|
app: Express;
|
|
@@ -9,6 +9,7 @@ export declare const parseDesignSystem: (sys: DevToolsSys, designSystemPackage?:
|
|
|
9
9
|
export declare const storeComponentDocs: (credentials: Credentials, body: StoreComponentDocsInput, debug?: boolean) => Promise<any>;
|
|
10
10
|
export declare const runCodeGen: (sys: DevToolsSys, credentials: Credentials, sessionId: string, message: GenerateUserMessage, debug?: boolean, designSystemPackage?: string, workspaceConfig?: WorkspaceConfiguration, opts?: {
|
|
11
11
|
tags?: object;
|
|
12
|
+
maxTokens?: number;
|
|
12
13
|
}, metadata?: any) => Promise<string>;
|
|
13
14
|
export declare const getAllDesignSystems: (credentials: Credentials) => Promise<DesignSystem[]>;
|
|
14
15
|
export declare const getDesignSystemByName: (credentials: Credentials, designSystemName: string) => Promise<DesignSystem | null>;
|
package/types/cli/utils/git.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { DevToolsSys } from "types";
|
|
2
|
-
interface RunGitOptions {
|
|
2
|
+
export interface RunGitOptions {
|
|
3
3
|
exec?: string;
|
|
4
4
|
cwd?: string;
|
|
5
5
|
debug?: boolean;
|
|
6
6
|
sys: DevToolsSys;
|
|
7
7
|
timeout?: number;
|
|
8
|
+
stdin?: string;
|
|
8
9
|
}
|
|
9
10
|
export declare function runGit(args: string[], opts: RunGitOptions): Promise<string>;
|
|
10
11
|
export declare const isGitRepoCorrupted: (stdout: string, stderr: string) => boolean;
|
|
11
|
-
export {};
|