Skip to content

Commit ef76665

Browse files
emmaling27Convex, Inc.
authored andcommitted
[CLI] Remove dead init code (#31126)
GitOrigin-RevId: 3b4c4eaf0a72fa70a194826d281eede5e400af21
1 parent 40a4965 commit ef76665

File tree

1 file changed

+0
-64
lines changed
  • npm-packages/convex/src/cli/lib

1 file changed

+0
-64
lines changed

npm-packages/convex/src/cli/lib/api.ts

Lines changed: 0 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -78,70 +78,6 @@ export async function createProject(
7878
};
7979
}
8080

81-
// Init
82-
// Provision a new empty project and return the new deployment credentials.
83-
export async function createProjectProvisioningDevOrProd(
84-
ctx: Context,
85-
{
86-
teamSlug: selectedTeamSlug,
87-
projectName,
88-
}: { teamSlug: string; projectName: string },
89-
firstDeploymentType: DeploymentType,
90-
): Promise<{
91-
projectSlug: string;
92-
teamSlug: string;
93-
deploymentName: string;
94-
url: string;
95-
adminKey: AdminKey;
96-
projectsRemaining: number;
97-
}> {
98-
const provisioningArgs = {
99-
team: selectedTeamSlug,
100-
projectName,
101-
deploymentType: firstDeploymentType,
102-
backendVersionOverride: process.env.CONVEX_BACKEND_VERSION_OVERRIDE,
103-
};
104-
const data = await bigBrainAPI({
105-
ctx,
106-
method: "POST",
107-
url: "create_project",
108-
data: provisioningArgs,
109-
});
110-
const {
111-
projectSlug,
112-
teamSlug,
113-
deploymentName,
114-
adminKey,
115-
projectsRemaining,
116-
prodUrl: url,
117-
} = data;
118-
if (
119-
projectSlug === undefined ||
120-
teamSlug === undefined ||
121-
deploymentName === undefined ||
122-
url === undefined ||
123-
adminKey === undefined ||
124-
projectsRemaining === undefined
125-
) {
126-
const error =
127-
"Unexpected response during provisioning: " + JSON.stringify(data);
128-
return await ctx.crash({
129-
exitCode: 1,
130-
errorType: "transient",
131-
errForSentry: error,
132-
printedMessage: error,
133-
});
134-
}
135-
return {
136-
projectSlug,
137-
teamSlug,
138-
deploymentName,
139-
url,
140-
adminKey,
141-
projectsRemaining,
142-
};
143-
}
144-
14581
// Dev
14682
export async function fetchDeploymentCredentialsForName(
14783
ctx: Context,

0 commit comments

Comments
 (0)