claude-autopm 1.13.7 → 1.13.8

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/install/install.js +46 -0
  2. package/package.json +1 -1
@@ -42,6 +42,7 @@ class Installer {
42
42
  '.claude/checklists',
43
43
  '.claude/strategies',
44
44
  '.claude/mcp',
45
+ '.claude/mcp-servers.json',
45
46
  '.claude/.env.example',
46
47
  '.claude/teams.json',
47
48
  '.claude-code'
@@ -774,6 +775,48 @@ See: https://github.com/rafeekpro/ClaudeAutoPM
774
775
  return processedContent;
775
776
  }
776
777
 
778
+ setupMCPIntegration() {
779
+ const mcpServersPath = path.join(this.targetDir, '.claude', 'mcp-servers.json');
780
+ const configPath = path.join(this.targetDir, '.claude', 'config.json');
781
+
782
+ // Check if MCP servers configuration exists
783
+ if (!fs.existsSync(mcpServersPath)) {
784
+ return; // No MCP configuration, skip
785
+ }
786
+
787
+ try {
788
+ // Read config to check for active servers
789
+ let hasActiveServers = false;
790
+ if (fs.existsSync(configPath)) {
791
+ const config = JSON.parse(fs.readFileSync(configPath, 'utf8'));
792
+ hasActiveServers = config.mcp?.activeServers?.length > 0;
793
+ }
794
+
795
+ // Read mcp-servers.json to check for any configured servers
796
+ const mcpConfig = JSON.parse(fs.readFileSync(mcpServersPath, 'utf8'));
797
+ const hasServers = Object.keys(mcpConfig.mcpServers || {}).length > 0;
798
+
799
+ if (hasServers) {
800
+ this.printStep('Setting up Claude Code MCP integration...');
801
+
802
+ // Create .mcp.json for Claude Code
803
+ const mcpJsonPath = path.join(this.targetDir, '.mcp.json');
804
+ const claudeCodeConfig = {
805
+ mcpServers: mcpConfig.mcpServers
806
+ };
807
+
808
+ fs.writeFileSync(mcpJsonPath, JSON.stringify(claudeCodeConfig, null, 2));
809
+ this.printSuccess('.mcp.json created for Claude Code');
810
+
811
+ if (!hasActiveServers) {
812
+ this.printMsg('CYAN', '💡 Tip: Run "autopm mcp enable <server>" to activate servers');
813
+ }
814
+ }
815
+ } catch (error) {
816
+ this.printWarning(`Could not setup MCP integration: ${error.message}`);
817
+ }
818
+ }
819
+
777
820
  async setupGitHooks() {
778
821
  const gitDir = path.join(this.targetDir, '.git');
779
822
  if (!fs.existsSync(gitDir)) {
@@ -852,6 +895,9 @@ See: https://github.com/rafeekpro/ClaudeAutoPM
852
895
  // Install CLAUDE.md
853
896
  this.installClaudeMd();
854
897
 
898
+ // Setup MCP integration for Claude Code
899
+ this.setupMCPIntegration();
900
+
855
901
  // Setup git hooks if requested
856
902
  if (this.options.setupHooks) {
857
903
  await this.setupGitHooks();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-autopm",
3
- "version": "1.13.7",
3
+ "version": "1.13.8",
4
4
  "description": "Autonomous Project Management Framework for Claude Code - Advanced AI-powered development automation",
5
5
  "main": "bin/autopm.js",
6
6
  "bin": {