create-line-harness 0.1.0 → 0.1.2
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/index.js +12 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -445,9 +445,17 @@ function generateMcpConfig(options) {
|
|
|
445
445
|
if (!mcpConfig.mcpServers) {
|
|
446
446
|
mcpConfig.mcpServers = {};
|
|
447
447
|
}
|
|
448
|
-
|
|
448
|
+
let serverName = "line-harness";
|
|
449
|
+
if (mcpConfig.mcpServers["line-harness"]) {
|
|
450
|
+
const suffix = options.apiKey.slice(0, 8);
|
|
451
|
+
serverName = `line-harness-${suffix}`;
|
|
452
|
+
p9.log.info(
|
|
453
|
+
`\u65E2\u5B58\u306E line-harness \u8A2D\u5B9A\u304C\u3042\u308B\u305F\u3081\u3001${serverName} \u3068\u3057\u3066\u8FFD\u52A0\u3057\u307E\u3059`
|
|
454
|
+
);
|
|
455
|
+
}
|
|
456
|
+
mcpConfig.mcpServers[serverName] = newServerConfig;
|
|
449
457
|
writeFileSync4(mcpJsonPath, JSON.stringify(mcpConfig, null, 2) + "\n");
|
|
450
|
-
p9.log.success(
|
|
458
|
+
p9.log.success(`.mcp.json \u306B MCP \u8A2D\u5B9A\u3092\u8FFD\u52A0\u3057\u307E\u3057\u305F\uFF08${serverName}\uFF09`);
|
|
451
459
|
}
|
|
452
460
|
|
|
453
461
|
// src/lib/crypto.ts
|
|
@@ -531,8 +539,8 @@ async function runSetup(repoDir) {
|
|
|
531
539
|
message: "LIFF ID",
|
|
532
540
|
placeholder: "\u30C1\u30E3\u30CD\u30EBID-\u30E9\u30F3\u30C0\u30E0\u6587\u5B57\u5217\uFF08\u4F8B: 2009554425-4IMBmLQ9\uFF09",
|
|
533
541
|
validate(value) {
|
|
534
|
-
if (!value || value.
|
|
535
|
-
return "LIFF ID \
|
|
542
|
+
if (!value || !value.includes("-")) {
|
|
543
|
+
return "LIFF ID \u306F\u300C\u30C1\u30E3\u30CD\u30EBID-\u30E9\u30F3\u30C0\u30E0\u6587\u5B57\u5217\u300D\u306E\u5F62\u5F0F\u3067\u3059\uFF08\u4F8B: 2009554425-4IMBmLQ9\uFF09";
|
|
536
544
|
}
|
|
537
545
|
}
|
|
538
546
|
});
|