From 5ce525b64dcb02dd4abadb2756160cfe0e28310e Mon Sep 17 00:00:00 2001 From: Fred Zhang Date: Mon, 23 Sep 2024 12:06:52 -0700 Subject: [PATCH 1/2] Default service ID to the name of the folder --- src/init/features/dataconnect/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/init/features/dataconnect/index.ts b/src/init/features/dataconnect/index.ts index 09c9c795538..15f96b37a56 100644 --- a/src/init/features/dataconnect/index.ts +++ b/src/init/features/dataconnect/index.ts @@ -1,4 +1,4 @@ -import { join } from "path"; +import { join, basename } from 'path'; import * as clc from "colorette"; import { confirm, promptOnce } from "../../../prompt"; @@ -295,7 +295,7 @@ async function promptForService( info.serviceId = await promptOnce({ message: "What ID would you like to use for this service?", type: "input", - default: "app", + default: basename(process.cwd()), }); } return info; From 1e13f10cfcab37ed550cf07d22a7faadee1d4125 Mon Sep 17 00:00:00 2001 From: Fred Zhang Date: Mon, 23 Sep 2024 12:10:42 -0700 Subject: [PATCH 2/2] m --- src/init/features/dataconnect/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/init/features/dataconnect/index.ts b/src/init/features/dataconnect/index.ts index 15f96b37a56..9e70bc96a0d 100644 --- a/src/init/features/dataconnect/index.ts +++ b/src/init/features/dataconnect/index.ts @@ -1,4 +1,4 @@ -import { join, basename } from 'path'; +import { join, basename } from "path"; import * as clc from "colorette"; import { confirm, promptOnce } from "../../../prompt";