create-prisma 0.13.1-pr.105.359.1 → 0.13.1
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/dist/cli.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { a as ApplicationLayer } from "./json-output-
|
|
2
|
+
import { a as ApplicationLayer } from "./json-output-CPdx9Prn.mjs";
|
|
3
3
|
import { runCreatePrismaCli } from "./index.mjs";
|
|
4
4
|
import { Effect } from "effect";
|
|
5
5
|
import { NodeRuntime } from "@effect/platform-node-shared";
|
package/dist/index.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { _ as authoringStyles, b as normalizeDatabaseProvider, c as CreateCommandResultSchema, d as AuthoringStyleSchema, f as CreateCommandInputSchema, g as agentSkillTargets, h as PackageManagerSchema, i as getErrorMessage, l as createCommandFailureResult, m as DatabaseProviderSchema, n as writeJsonResult, o as applicationRuntime, p as CreateTemplateSchema, r as runCreateCommandEffect, s as CREATE_PRISMA_RESULT_SCHEMA_VERSION, t as isJsonOutputRequested, u as AgentSkillTargetSchema, v as createTemplates, x as packageManagers, y as databaseProviderInputs } from "./json-output-
|
|
2
|
+
import { _ as authoringStyles, b as normalizeDatabaseProvider, c as CreateCommandResultSchema, d as AuthoringStyleSchema, f as CreateCommandInputSchema, g as agentSkillTargets, h as PackageManagerSchema, i as getErrorMessage, l as createCommandFailureResult, m as DatabaseProviderSchema, n as writeJsonResult, o as applicationRuntime, p as CreateTemplateSchema, r as runCreateCommandEffect, s as CREATE_PRISMA_RESULT_SCHEMA_VERSION, t as isJsonOutputRequested, u as AgentSkillTargetSchema, v as createTemplates, x as packageManagers, y as databaseProviderInputs } from "./json-output-CPdx9Prn.mjs";
|
|
3
3
|
import { Console, Effect, Option } from "effect";
|
|
4
4
|
import { Argument, CliError, Command, Flag } from "effect/unstable/cli";
|
|
5
5
|
|
|
6
6
|
//#region src/index.ts
|
|
7
|
-
const CLI_VERSION = "0.13.1
|
|
7
|
+
const CLI_VERSION = "0.13.1";
|
|
8
8
|
const optionalArgument = (name, description) => Argument.string(name).pipe(Argument.withDescription(description), Argument.optional, Argument.map(Option.getOrUndefined));
|
|
9
9
|
const optionalBoolean = (name, description) => Flag.boolean(name).pipe(Flag.withDescription(description), Flag.optional, Flag.map(Option.getOrUndefined));
|
|
10
10
|
const optionalString = (name, description) => Flag.string(name).pipe(Flag.withDescription(description), Flag.optional, Flag.map(Option.getOrUndefined));
|
|
@@ -388,14 +388,20 @@ const applicationRuntime = ManagedRuntime.make(ApplicationLayer);
|
|
|
388
388
|
|
|
389
389
|
//#endregion
|
|
390
390
|
//#region src/telemetry/client.ts
|
|
391
|
-
const TELEMETRY_API_KEY = "";
|
|
391
|
+
const TELEMETRY_API_KEY = "phc_cmc85avbWyuJ2JyKdGPdv7dxXli8xLdWDBPbvIXWJfs";
|
|
392
392
|
const TELEMETRY_HOST = "https://us.i.posthog.com";
|
|
393
393
|
const TELEMETRY_CONFIG_FILE = "telemetry.json";
|
|
394
394
|
const TELEMETRY_TIMEOUT_MS = 2e3;
|
|
395
395
|
const AnonymousId = Schema.String.check(Schema.isUUID(4));
|
|
396
396
|
const decodeAnonymousId = Schema.decodeUnknownExit(AnonymousId);
|
|
397
|
+
const isTruthyEnvValue = (value) => [
|
|
398
|
+
"1",
|
|
399
|
+
"true",
|
|
400
|
+
"yes",
|
|
401
|
+
"on"
|
|
402
|
+
].includes(String(value ?? "").trim().toLowerCase());
|
|
397
403
|
function shouldDisableTelemetry() {
|
|
398
|
-
return
|
|
404
|
+
return isTruthyEnvValue(process.env.CI) || isTruthyEnvValue(process.env.GITHUB_ACTIONS) || process.env.CREATE_PRISMA_DISABLE_TELEMETRY !== void 0 || process.env.CREATE_PRISMA_TELEMETRY_DISABLED !== void 0 || process.env.DO_NOT_TRACK !== void 0;
|
|
399
405
|
}
|
|
400
406
|
function getTelemetryConfigDir() {
|
|
401
407
|
if (process.platform === "darwin") return path.join(os.homedir(), "Library", "Application Support", "create-prisma");
|
|
@@ -418,7 +424,7 @@ const getAnonymousIdEffect = Effect.fn("Telemetry.getAnonymousId")(function* ()
|
|
|
418
424
|
return anonymousId;
|
|
419
425
|
});
|
|
420
426
|
const getCommonProperties = () => ({
|
|
421
|
-
"cli-version": "0.13.1
|
|
427
|
+
"cli-version": "0.13.1",
|
|
422
428
|
"node-version": process.version,
|
|
423
429
|
platform: process.platform,
|
|
424
430
|
arch: process.arch
|
package/package.json
CHANGED