create-better-t-stack 2.32.0 → 2.32.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.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { createBtsCli } from "./src-BEEshIQf.js";
2
+ import { createBtsCli } from "./src-DJffJtr1.js";
3
3
 
4
4
  //#region src/cli.ts
5
5
  createBtsCli().run();
package/dist/index.d.ts CHANGED
@@ -125,6 +125,7 @@ type CreateInput = {
125
125
  webDeploy?: WebDeploy;
126
126
  directoryConflict?: DirectoryConflict;
127
127
  renderTitle?: boolean;
128
+ disableAnalytics?: boolean;
128
129
  };
129
130
  type AddInput = {
130
131
  addons?: Addons[];
@@ -207,6 +208,7 @@ declare const router: trpcServer.TRPCBuiltRouter<{
207
208
  webDeploy?: "none" | "workers" | undefined;
208
209
  directoryConflict?: "error" | "merge" | "overwrite" | "increment" | undefined;
209
210
  renderTitle?: boolean | undefined;
211
+ disableAnalytics?: boolean | undefined;
210
212
  }];
211
213
  output: InitResult | undefined;
212
214
  meta: object;
@@ -262,6 +264,7 @@ declare function createBtsCli(): trpc_cli0.TrpcCli;
262
264
  * packageManager: "bun",
263
265
  * install: false,
264
266
  * directoryConflict: "increment", // auto-handle conflicts
267
+ * disableAnalytics: true, // disable analytics
265
268
  * });
266
269
  *
267
270
  * if (result.success) {
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import { builder, createBtsCli, docs, init, router, sponsors } from "./src-BEEshIQf.js";
2
+ import { builder, createBtsCli, docs, init, router, sponsors } from "./src-DJffJtr1.js";
3
3
 
4
4
  export { builder, createBtsCli, docs, init, router, sponsors };
@@ -1212,8 +1212,8 @@ function isTelemetryEnabled() {
1212
1212
  //#region src/utils/analytics.ts
1213
1213
  const POSTHOG_API_KEY = "phc_8ZUxEwwfKMajJLvxz1daGd931dYbQrwKNficBmsdIrs";
1214
1214
  const POSTHOG_HOST = "https://us.i.posthog.com";
1215
- async function trackProjectCreation(config) {
1216
- if (!isTelemetryEnabled()) return;
1215
+ async function trackProjectCreation(config, disableAnalytics = false) {
1216
+ if (!isTelemetryEnabled() || disableAnalytics) return;
1217
1217
  const sessionId = `cli_${crypto.randomUUID().replace(/-/g, "")}`;
1218
1218
  const { projectName, projectDir, relativePath,...safeConfig } = config;
1219
1219
  const payload = {
@@ -5229,7 +5229,7 @@ async function createProjectHandler(input) {
5229
5229
  await createProject(config);
5230
5230
  const reproducibleCommand = generateReproducibleCommand(config);
5231
5231
  log.success(pc.blue(`You can reproduce this setup with the following command:\n${reproducibleCommand}`));
5232
- await trackProjectCreation(config);
5232
+ await trackProjectCreation(config, input.disableAnalytics);
5233
5233
  const elapsedTimeMs = Date.now() - startTime;
5234
5234
  const elapsedTimeInSeconds = (elapsedTimeMs / 1e3).toFixed(2);
5235
5235
  outro(pc.magenta(`Project created successfully in ${pc.bold(elapsedTimeInSeconds)} seconds!`));
@@ -5418,7 +5418,8 @@ const router = t.router({
5418
5418
  api: APISchema.optional(),
5419
5419
  webDeploy: WebDeploySchema.optional(),
5420
5420
  directoryConflict: DirectoryConflictSchema.optional(),
5421
- renderTitle: z.boolean().optional()
5421
+ renderTitle: z.boolean().optional(),
5422
+ disableAnalytics: z.boolean().optional().default(false).describe("Disable analytics")
5422
5423
  })])).mutation(async ({ input }) => {
5423
5424
  const [projectName, options] = input;
5424
5425
  const combinedInput = {
@@ -5498,6 +5499,7 @@ function createBtsCli() {
5498
5499
  * packageManager: "bun",
5499
5500
  * install: false,
5500
5501
  * directoryConflict: "increment", // auto-handle conflicts
5502
+ * disableAnalytics: true, // disable analytics
5501
5503
  * });
5502
5504
  *
5503
5505
  * if (result.success) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-better-t-stack",
3
- "version": "2.32.0",
3
+ "version": "2.32.1",
4
4
  "description": "A modern CLI tool for scaffolding end-to-end type-safe TypeScript projects with best practices and customizable configurations",
5
5
  "type": "module",
6
6
  "license": "MIT",