fa-mcp-sdk 0.2.96 → 0.2.98

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.
Files changed (2) hide show
  1. package/bin/fa-mcp.js +16 -2
  2. package/package.json +1 -1
package/bin/fa-mcp.js CHANGED
@@ -202,6 +202,7 @@ certificate's public and private keys`,
202
202
  },
203
203
  {
204
204
  title: 'Is it Production mode',
205
+ defaultValue: 'false',
205
206
  name: 'isProduction',
206
207
  },
207
208
  {
@@ -258,7 +259,6 @@ certificate's public and private keys`,
258
259
 
259
260
  async collectConfigData (config, isRetry = false) {
260
261
  const ask = getAsk();
261
-
262
262
  // Collect required parameters
263
263
  for (const param of this.requiredParams) {
264
264
  const { title, name } = param;
@@ -427,6 +427,7 @@ certificate's public and private keys`,
427
427
  if (skip) {
428
428
  continue;
429
429
  }
430
+
430
431
  let value;
431
432
  switch (name) {
432
433
  case 'git-base-url':
@@ -460,7 +461,7 @@ certificate's public and private keys`,
460
461
  config.maintainerHtml = `<a href="${value}" target="_blank" rel="noopener" class="clickable">Support</a>`;
461
462
  }
462
463
  continue;
463
- case 'logger.useFileLogger':
464
+ case 'logger.useFileLogger': {
464
465
  const enabled = await ask.yn(title, name, defaultValue);
465
466
  config[name] = String(enabled);
466
467
  if (enabled) {
@@ -474,6 +475,12 @@ certificate's public and private keys`,
474
475
  config[nm] = '';
475
476
  }
476
477
  continue;
478
+ }
479
+ case 'isProduction': {
480
+ const enabled = await ask.yn(title, name, defaultValue);
481
+ config[name] = String(enabled);
482
+ continue;
483
+ }
477
484
  default:
478
485
  value = await ask.optional(title, name, defaultValue);
479
486
  }
@@ -546,6 +553,12 @@ certificate's public and private keys`,
546
553
  }
547
554
  }
548
555
 
556
+ if (configProxy.NODE_ENV === 'development') {
557
+ configProxy.isProduction = 'false';
558
+ } else if (configProxy.NODE_ENV === 'production') {
559
+ configProxy.isProduction = 'true';
560
+ }
561
+
549
562
  let confirmed = false;
550
563
  let isRetry = false;
551
564
 
@@ -556,6 +569,7 @@ certificate's public and private keys`,
556
569
  // Set NODE_ENV and PM2_NAMESPACE based on isProduction
557
570
  config.NODE_ENV = config.isProduction === 'true' ? 'production' : 'development';
558
571
  config.PM2_NAMESPACE = config.isProduction === 'true' ? 'prod' : 'dev';
572
+ config.SERVICE_INSTANCE = config.PM2_NAMESPACE;
559
573
 
560
574
  confirmed = await this.confirmConfiguration(config);
561
575
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "fa-mcp-sdk",
3
3
  "productName": "FA MCP SDK",
4
- "version": "0.2.96",
4
+ "version": "0.2.98",
5
5
  "description": "Core infrastructure and templates for building Model Context Protocol (MCP) servers with TypeScript",
6
6
  "type": "module",
7
7
  "main": "dist/core/index.js",