@mcp-use/cli 3.5.3-canary.8 → 3.6.0-canary.11
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/commands/deploy.d.ts +10 -0
- package/dist/commands/deploy.d.ts.map +1 -1
- package/dist/commands/servers.d.ts.map +1 -1
- package/dist/index.cjs +80 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +80 -6
- package/dist/index.js.map +1 -1
- package/dist/utils/api.d.ts +16 -0
- package/dist/utils/api.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -32,6 +32,16 @@ interface DeployOptions {
|
|
|
32
32
|
startCommand?: string;
|
|
33
33
|
/** Path to a non-default Dockerfile (relative to rootDir / repo root). */
|
|
34
34
|
dockerfile?: string;
|
|
35
|
+
/**
|
|
36
|
+
* Glob patterns limiting which repo changes trigger auto-deploy (monorepos).
|
|
37
|
+
* Applied only when creating a new GitHub server.
|
|
38
|
+
*/
|
|
39
|
+
watchPaths?: string[];
|
|
40
|
+
/**
|
|
41
|
+
* Hold GitHub auto-deploys until other check runs pass. Applied only when
|
|
42
|
+
* creating a new GitHub server.
|
|
43
|
+
*/
|
|
44
|
+
waitForCi?: boolean;
|
|
35
45
|
/**
|
|
36
46
|
* Deploy branch. Defaults to the current git branch (managed flow: "main").
|
|
37
47
|
* Also scopes env-var sync to that branch's preview env.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/commands/deploy.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,cAAc,EAGf,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAGL,SAAS,EACV,MAAM,iBAAiB,CAAC;AAgGzB;;;;;;;;GAQG;AACH,wBAAsB,mBAAmB,CACvC,GAAG,EAAE,SAAS,EACd,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC/B,IAAI,CAAC,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
|
|
1
|
-
{"version":3,"file":"servers.d.ts","sourceRoot":"","sources":["../../src/commands/servers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"servers.d.ts","sourceRoot":"","sources":["../../src/commands/servers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAygBpC,wBAAgB,oBAAoB,IAAI,OAAO,CA0E9C"}
|
package/dist/index.cjs
CHANGED
|
@@ -6192,7 +6192,9 @@ async function deployCommand(options) {
|
|
|
6192
6192
|
region: options.region,
|
|
6193
6193
|
buildCommand: options.buildCommand,
|
|
6194
6194
|
startCommand: options.startCommand,
|
|
6195
|
-
dockerfilePath: options.dockerfile
|
|
6195
|
+
dockerfilePath: options.dockerfile,
|
|
6196
|
+
watchPaths: options.watchPaths,
|
|
6197
|
+
waitForCi: options.waitForCi
|
|
6196
6198
|
});
|
|
6197
6199
|
deploymentId = serverResult.deploymentId ?? "";
|
|
6198
6200
|
if (!deploymentId) {
|
|
@@ -7136,6 +7138,25 @@ async function getServerCommand(idOrSlug, options) {
|
|
|
7136
7138
|
console.log(
|
|
7137
7139
|
source_default.white(" Prod branch: ") + source_default.gray(cr.productionBranch)
|
|
7138
7140
|
);
|
|
7141
|
+
if (cr.watchPaths !== void 0) {
|
|
7142
|
+
console.log(
|
|
7143
|
+
source_default.white(" Watch paths: ") + source_default.gray(
|
|
7144
|
+
cr.watchPaths.length > 0 ? cr.watchPaths.join(", ") : "(all changes)"
|
|
7145
|
+
)
|
|
7146
|
+
);
|
|
7147
|
+
}
|
|
7148
|
+
if (cr.deployBranchPatterns !== void 0) {
|
|
7149
|
+
console.log(
|
|
7150
|
+
source_default.white(" Deploy branches: ") + source_default.gray(
|
|
7151
|
+
cr.deployBranchPatterns.length > 0 ? cr.deployBranchPatterns.join(", ") : "(all branches)"
|
|
7152
|
+
)
|
|
7153
|
+
);
|
|
7154
|
+
}
|
|
7155
|
+
if (cr.waitForCi !== void 0) {
|
|
7156
|
+
console.log(
|
|
7157
|
+
source_default.white(" Wait for CI: ") + source_default.gray(cr.waitForCi ? "yes" : "no")
|
|
7158
|
+
);
|
|
7159
|
+
}
|
|
7139
7160
|
}
|
|
7140
7161
|
if (server.activeDeploymentId) {
|
|
7141
7162
|
console.log(
|
|
@@ -7195,7 +7216,10 @@ async function getServerCommand(idOrSlug, options) {
|
|
|
7195
7216
|
handleCommandError(error, "Failed to get server");
|
|
7196
7217
|
}
|
|
7197
7218
|
}
|
|
7198
|
-
|
|
7219
|
+
function resolveGlobList(values) {
|
|
7220
|
+
return values.map((v) => v.trim()).filter((v) => v.length > 0);
|
|
7221
|
+
}
|
|
7222
|
+
async function updateServerCommand(idOrSlug, options, command) {
|
|
7199
7223
|
try {
|
|
7200
7224
|
if (!await isLoggedIn()) {
|
|
7201
7225
|
console.log(source_default.red("\u2717 You are not logged in."));
|
|
@@ -7211,6 +7235,13 @@ async function updateServerCommand(idOrSlug, options) {
|
|
|
7211
7235
|
if (options.description !== void 0)
|
|
7212
7236
|
body.description = options.description;
|
|
7213
7237
|
if (options.branch !== void 0) body.productionBranch = options.branch;
|
|
7238
|
+
if (options.watchPaths !== void 0)
|
|
7239
|
+
body.watchPaths = resolveGlobList(options.watchPaths);
|
|
7240
|
+
if (options.deployBranches !== void 0)
|
|
7241
|
+
body.deployBranchPatterns = resolveGlobList(options.deployBranches);
|
|
7242
|
+
if (options.waitForCi !== void 0 && command?.getOptionValueSource("waitForCi") === "cli") {
|
|
7243
|
+
body.waitForCi = options.waitForCi;
|
|
7244
|
+
}
|
|
7214
7245
|
const config = {};
|
|
7215
7246
|
if (options.buildCommand !== void 0) {
|
|
7216
7247
|
config.buildCommand = options.buildCommand === "" ? null : options.buildCommand;
|
|
@@ -7218,11 +7249,14 @@ async function updateServerCommand(idOrSlug, options) {
|
|
|
7218
7249
|
if (options.startCommand !== void 0) {
|
|
7219
7250
|
config.startCommand = options.startCommand === "" ? null : options.startCommand;
|
|
7220
7251
|
}
|
|
7252
|
+
if (options.rootDir !== void 0) {
|
|
7253
|
+
config.rootDir = options.rootDir === "" ? null : options.rootDir;
|
|
7254
|
+
}
|
|
7221
7255
|
if (Object.keys(config).length > 0) body.config = config;
|
|
7222
7256
|
if (Object.keys(body).length === 0) {
|
|
7223
7257
|
console.error(
|
|
7224
7258
|
source_default.red(
|
|
7225
|
-
"\u2717 Nothing to update. Provide at least one of: --branch, --name, --build-command, --start-command, --description."
|
|
7259
|
+
"\u2717 Nothing to update. Provide at least one of: --branch, --name, --build-command, --start-command, --description, --watch-paths, --deploy-branches, --wait-for-ci/--no-wait-for-ci, --root-dir."
|
|
7226
7260
|
)
|
|
7227
7261
|
);
|
|
7228
7262
|
process.exit(1);
|
|
@@ -7234,10 +7268,30 @@ async function updateServerCommand(idOrSlug, options) {
|
|
|
7234
7268
|
const label = server.name || server.slug || server.id;
|
|
7235
7269
|
console.log(source_default.green.bold(`
|
|
7236
7270
|
\u2713 Server updated: ${label}`));
|
|
7237
|
-
|
|
7271
|
+
const repo = server.connectedRepository;
|
|
7272
|
+
if (repo) {
|
|
7238
7273
|
console.log(
|
|
7239
|
-
source_default.gray(" Prod branch: ") + source_default.cyan(
|
|
7274
|
+
source_default.gray(" Prod branch: ") + source_default.cyan(repo.productionBranch)
|
|
7240
7275
|
);
|
|
7276
|
+
if (repo.watchPaths !== void 0) {
|
|
7277
|
+
console.log(
|
|
7278
|
+
source_default.gray(" Watch paths: ") + source_default.cyan(
|
|
7279
|
+
repo.watchPaths.length > 0 ? repo.watchPaths.join(", ") : "(all changes)"
|
|
7280
|
+
)
|
|
7281
|
+
);
|
|
7282
|
+
}
|
|
7283
|
+
if (repo.deployBranchPatterns !== void 0) {
|
|
7284
|
+
console.log(
|
|
7285
|
+
source_default.gray(" Deploy branches: ") + source_default.cyan(
|
|
7286
|
+
repo.deployBranchPatterns.length > 0 ? repo.deployBranchPatterns.join(", ") : "(all branches)"
|
|
7287
|
+
)
|
|
7288
|
+
);
|
|
7289
|
+
}
|
|
7290
|
+
if (repo.waitForCi !== void 0) {
|
|
7291
|
+
console.log(
|
|
7292
|
+
source_default.gray(" Wait for CI: ") + source_default.cyan(repo.waitForCi ? "yes" : "no")
|
|
7293
|
+
);
|
|
7294
|
+
}
|
|
7241
7295
|
}
|
|
7242
7296
|
console.log();
|
|
7243
7297
|
} catch (error) {
|
|
@@ -7312,7 +7366,19 @@ function createServersCommand() {
|
|
|
7312
7366
|
).option(
|
|
7313
7367
|
"--start-command <cmd>",
|
|
7314
7368
|
"Override the start command (pass an empty string to clear)"
|
|
7315
|
-
).option("--description <text>", "Update the server description").option(
|
|
7369
|
+
).option("--description <text>", "Update the server description").option(
|
|
7370
|
+
"--watch-paths <glob...>",
|
|
7371
|
+
'Only auto-deploy when files matching these globs change (monorepos). Pass "" to clear.'
|
|
7372
|
+
).option(
|
|
7373
|
+
"--deploy-branches <glob...>",
|
|
7374
|
+
'Branch globs allowed to trigger auto-deploys (besides the production branch). Pass "" to allow all.'
|
|
7375
|
+
).option(
|
|
7376
|
+
"--wait-for-ci",
|
|
7377
|
+
"Hold GitHub auto-deploys until other check runs pass"
|
|
7378
|
+
).option("--no-wait-for-ci", "Do not wait for other check runs").option(
|
|
7379
|
+
"--root-dir <path>",
|
|
7380
|
+
'Repo subdirectory to build from (monorepos). Pass "" to reset to the repo root.'
|
|
7381
|
+
).option("--org <slug-or-id>", "Target organization").action(updateServerCommand);
|
|
7316
7382
|
serversCommand.command("delete").alias("rm").argument("<server-id>", "Server UUID (or slug if API accepts it)").option("-y, --yes", "Skip confirmation prompt").option("--org <slug-or-id>", "Target organization").description("Delete a server and all its deployments").action(deleteServerCommand);
|
|
7317
7383
|
serversCommand.addCommand(createEnvCommand());
|
|
7318
7384
|
return serversCommand;
|
|
@@ -9936,6 +10002,12 @@ program.command("deploy").description("Deploy MCP server from GitHub to Manufact
|
|
|
9936
10002
|
).option(
|
|
9937
10003
|
"--dockerfile <path>",
|
|
9938
10004
|
"Path to a non-default Dockerfile (relative to rootDir / repo root)"
|
|
10005
|
+
).option(
|
|
10006
|
+
"--watch-paths <glob...>",
|
|
10007
|
+
"Only auto-deploy when files matching these globs change (monorepos). Set on new-server creation."
|
|
10008
|
+
).option(
|
|
10009
|
+
"--wait-for-ci",
|
|
10010
|
+
"Hold GitHub auto-deploys until other check runs pass. Set on new-server creation."
|
|
9939
10011
|
).option(
|
|
9940
10012
|
"--no-github",
|
|
9941
10013
|
"Upload local source without connecting GitHub (repo hosted in the platform-managed org)"
|
|
@@ -9956,6 +10028,8 @@ program.command("deploy").description("Deploy MCP server from GitHub to Manufact
|
|
|
9956
10028
|
buildCommand: options.buildCommand,
|
|
9957
10029
|
startCommand: options.startCommand,
|
|
9958
10030
|
dockerfile: options.dockerfile,
|
|
10031
|
+
watchPaths: options.watchPaths,
|
|
10032
|
+
waitForCi: options.waitForCi,
|
|
9959
10033
|
noGithub: options.github === false
|
|
9960
10034
|
});
|
|
9961
10035
|
});
|