@insforge/install 0.0.19 → 0.0.21

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 (3) hide show
  1. package/README.md +18 -1
  2. package/dist/index.js +15 -10
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -14,6 +14,9 @@ npx @insforge/install --client roocode --env API_KEY=YOUR_API_KEY --env API_BASE
14
14
  npx @insforge/install --client codex --env API_KEY=YOUR_API_KEY --env API_BASE_URL=http://localhost:7130
15
15
  npx @insforge/install --client trae --env API_KEY=YOUR_API_KEY --env API_BASE_URL=http://localhost:7130
16
16
 
17
+ # Install dev version for testing (uses @insforge/mcp@dev)
18
+ npx @insforge/install --client cursor --env API_KEY=YOUR_API_KEY --env API_BASE_URL=http://localhost:7130 --dev
19
+
17
20
  # With custom base URL (e.g., production server)
18
21
  npx @insforge/install --client cursor --env API_KEY=YOUR_API_KEY --env API_BASE_URL=https://api.insforge.com
19
22
  ```
@@ -38,6 +41,7 @@ npx @insforge/install --client cursor --env API_KEY=YOUR_API_KEY --env API_BASE_
38
41
  --env KEY=VALUE Environment variables (can be used multiple times)
39
42
  API_KEY is required
40
43
  API_BASE_URL is optional (default: http://localhost:7130)
44
+ --dev Install dev version (@insforge/mcp@dev) instead of latest
41
45
  ```
42
46
 
43
47
  ## Examples
@@ -49,6 +53,9 @@ npx @insforge/install --client claude-code --env API_KEY=your-api-key-here --env
49
53
 
50
54
  # Install for Windsurf with production server
51
55
  npx @insforge/install --client windsurf --env API_KEY=your-api-key --env API_BASE_URL=https://api.insforge.com
56
+
57
+ # Install dev version for internal testing
58
+ npx @insforge/install --client cursor --env API_KEY=your-api-key --env API_BASE_URL=http://localhost:7130 --dev
52
59
  ```
53
60
 
54
61
  ### What This Does
@@ -56,10 +63,20 @@ npx @insforge/install --client windsurf --env API_KEY=your-api-key --env API_BAS
56
63
  The installer will:
57
64
  1. Create or update the MCP configuration file for your chosen client
58
65
  2. Add the Insforge MCP server with your API credentials
59
- 3. Configure it to run via `npx @insforge/mcp@latest`
66
+ 3. Configure it to run via `npx @insforge/mcp@latest` (or `@insforge/mcp@dev` with `--dev` flag)
60
67
 
61
68
  After installation, restart your AI client to load the Insforge MCP server.
62
69
 
70
+ ### Dev vs Production Versions
71
+
72
+ - **Production** (default): `npx @insforge/install --client <client> ...`
73
+ - Installs `@insforge/mcp@latest` - stable, tested version
74
+ - Recommended for general use
75
+
76
+ - **Development** (`--dev` flag): `npx @insforge/install --client <client> ... --dev`
77
+ - Installs `@insforge/mcp@dev` - latest features, may be unstable
78
+ - For team testing and early access to new features
79
+
63
80
  ## License
64
81
 
65
82
  MIT
package/dist/index.js CHANGED
@@ -6,7 +6,9 @@ import {
6
6
  writeConfig
7
7
  } from "./utils.js";
8
8
  import { execSync } from 'child_process';
9
-
9
+ import os from 'os';
10
+ import path from 'path';
11
+
10
12
  import yargs from "yargs";
11
13
  import { hideBin } from "yargs/helpers";
12
14
 
@@ -22,6 +24,10 @@ import {
22
24
  type: "string",
23
25
  description: "Environment variables as key=value pairs (can be used multiple times). API_KEY is required.",
24
26
  array: true
27
+ }).option("dev", {
28
+ type: "boolean",
29
+ description: "Install dev version (@insforge/mcp@dev) instead of latest",
30
+ default: false
25
31
  });
26
32
  }
27
33
  async function handler(argv) {
@@ -49,6 +55,7 @@ import {
49
55
  envVars.API_BASE_URL = "http://localhost:7130";
50
56
  }
51
57
  const name = "insforge";
58
+ const mcpVersion = argv.dev ? "@insforge/mcp@dev" : "@insforge/mcp@latest";
52
59
  const ready = true; // Auto-confirm for simplified installation
53
60
  if (ready) {
54
61
  try {
@@ -57,8 +64,6 @@ import {
57
64
  // Handle different config structures for different clients
58
65
  if (argv.client === "claude-code") {
59
66
  // Use Claude CLI for Claude Code
60
- const os = require('os');
61
- const path = require('path');
62
67
  const homeDir = os.homedir();
63
68
  const isWindows = process.platform === 'win32';
64
69
  const claudePath = isWindows
@@ -84,8 +89,8 @@ import {
84
89
  }
85
90
 
86
91
  // Now add the MCP server
87
- const command = `"${claudePath}" mcp add ${name} ${envArgs} -- npx -y @insforge/mcp@latest`;
88
- logger.info("Adding insforge MCP server...");
92
+ const command = `"${claudePath}" mcp add ${name} ${envArgs} -- npx -y ${mcpVersion}`;
93
+ logger.info(`Adding insforge MCP server (${mcpVersion})...`);
89
94
  execSync(command, {
90
95
  stdio: 'inherit',
91
96
  shell: true
@@ -117,8 +122,8 @@ import {
117
122
  }
118
123
 
119
124
  // Now add the MCP server using codex CLI with --env flags
120
- const command = `codex mcp add ${name} ${envArgs} -- npx -y @insforge/mcp@latest`;
121
- logger.info("Adding insforge MCP server...");
125
+ const command = `codex mcp add ${name} ${envArgs} -- npx -y ${mcpVersion}`;
126
+ logger.info(`Adding insforge MCP server (${mcpVersion})...`);
122
127
  execSync(command, {
123
128
  stdio: 'inherit',
124
129
  shell: true
@@ -131,7 +136,7 @@ import {
131
136
  if (!config.mcpServers) config.mcpServers = {};
132
137
  config.mcpServers[name] = {
133
138
  command: "npx",
134
- args: ["-y", "@insforge/mcp@latest"],
139
+ args: ["-y", mcpVersion],
135
140
  env: {
136
141
  API_KEY: envVars.API_KEY,
137
142
  API_BASE_URL: envVars.API_BASE_URL
@@ -142,7 +147,7 @@ import {
142
147
  if (!config.mcpServers) config.mcpServers = {};
143
148
  config.mcpServers[name] = {
144
149
  command: "npx",
145
- args: ["-y", "@insforge/mcp@latest"],
150
+ args: ["-y", mcpVersion],
146
151
  env: {
147
152
  API_KEY: envVars.API_KEY,
148
153
  API_BASE_URL: envVars.API_BASE_URL
@@ -153,7 +158,7 @@ import {
153
158
  if (!config.mcpServers) config.mcpServers = {};
154
159
  config.mcpServers[name] = {
155
160
  command: "npx",
156
- args: ["-y", "@insforge/mcp@latest"],
161
+ args: ["-y", mcpVersion],
157
162
  env: {
158
163
  API_KEY: envVars.API_KEY,
159
164
  API_BASE_URL: envVars.API_BASE_URL
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@insforge/install",
3
- "version": "0.0.19",
3
+ "version": "0.0.21",
4
4
  "description": "CLI tool for installing Insforge MCP servers across different AI clients",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",