@multiplayer-app/cli 2.0.2 → 2.0.4

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/dist/index.js +24 -25
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -106342,7 +106342,7 @@ var require_form_data = __commonJS((exports, module2) => {
106342
106342
  var http = __require("http");
106343
106343
  var https = __require("https");
106344
106344
  var parseUrl = __require("url").parse;
106345
- var fs6 = __require("fs");
106345
+ var fs7 = __require("fs");
106346
106346
  var Stream3 = __require("stream").Stream;
106347
106347
  var crypto2 = __require("crypto");
106348
106348
  var mime = require_mime_types();
@@ -106410,7 +106410,7 @@ var require_form_data = __commonJS((exports, module2) => {
106410
106410
  if (value2.end != null && value2.end != Infinity && value2.start != null) {
106411
106411
  callback(null, value2.end + 1 - (value2.start ? value2.start : 0));
106412
106412
  } else {
106413
- fs6.stat(value2.path, function(err, stat) {
106413
+ fs7.stat(value2.path, function(err, stat) {
106414
106414
  if (err) {
106415
106415
  callback(err);
106416
106416
  return;
@@ -107460,7 +107460,7 @@ var require_once = __commonJS((exports, module2) => {
107460
107460
  // ../../node_modules/formidable/dist/index.cjs
107461
107461
  var require_dist4 = __commonJS((exports) => {
107462
107462
  Object.defineProperty(exports, "__esModule", { value: true });
107463
- var fs6 = __require("fs");
107463
+ var fs7 = __require("fs");
107464
107464
  var crypto2 = __require("crypto");
107465
107465
  var node_events = __require("events");
107466
107466
  var cuid2 = require_cuid2();
@@ -107486,7 +107486,7 @@ var require_dist4 = __commonJS((exports) => {
107486
107486
  }
107487
107487
  }
107488
107488
  open() {
107489
- this._writeStream = fs6.createWriteStream(this.filepath);
107489
+ this._writeStream = fs7.createWriteStream(this.filepath);
107490
107490
  this._writeStream.on("error", (err) => {
107491
107491
  this.emit("error", err);
107492
107492
  });
@@ -107537,7 +107537,7 @@ var require_dist4 = __commonJS((exports) => {
107537
107537
  this._writeStream.destroy();
107538
107538
  const filepath = this.filepath;
107539
107539
  setTimeout(function() {
107540
- fs6.unlink(filepath, () => {});
107540
+ fs7.unlink(filepath, () => {});
107541
107541
  }, 1);
107542
107542
  }
107543
107543
  }
@@ -110129,7 +110129,7 @@ var require_node4 = __commonJS((exports, module2) => {
110129
110129
  var Stream3 = __require("stream");
110130
110130
  var https = __require("https");
110131
110131
  var http = __require("http");
110132
- var fs6 = __require("fs");
110132
+ var fs7 = __require("fs");
110133
110133
  var zlib = __require("zlib");
110134
110134
  var util3 = __require("util");
110135
110135
  var qs = require_lib7();
@@ -110240,7 +110240,7 @@ var require_node4 = __commonJS((exports, module2) => {
110240
110240
  if (!o.filename)
110241
110241
  o.filename = file;
110242
110242
  debug13("creating `fs.ReadStream` instance for file: %s", file);
110243
- file = fs6.createReadStream(file);
110243
+ file = fs7.createReadStream(file);
110244
110244
  file.on("error", (error3) => {
110245
110245
  const formData = this._getFormData();
110246
110246
  formData.emit("error", error3);
@@ -163604,13 +163604,7 @@ var processClaudeStreamEvent = (event, callbacks, pendingToolCallRef, runningToo
163604
163604
  }
163605
163605
  };
163606
163606
  var runOpenAiLoop = async (client, model, messages, projectDir, abortSignal, callbacks, handleExtraTool) => {
163607
- const {
163608
- onProgress,
163609
- onToolCall,
163610
- onToolCallResult,
163611
- onTurnStart,
163612
- confirmToolCall
163613
- } = callbacks;
163607
+ const { onProgress, onToolCall, onToolCallResult, onTurnStart, confirmToolCall } = callbacks;
163614
163608
  let filesRead = 0;
163615
163609
  let patches = [];
163616
163610
  let finalContent = "";
@@ -163746,6 +163740,7 @@ var resolveIssueWithClaudeCode = async (_issue, projectDir, prompt, model, abort
163746
163740
  prompt,
163747
163741
  options: {
163748
163742
  cwd: projectDir,
163743
+ executable: "node",
163749
163744
  permissionMode: "bypassPermissions",
163750
163745
  systemPrompt: buildSystemPrompt(projectDir),
163751
163746
  maxTurns: 1000,
@@ -163777,11 +163772,7 @@ var resolveIssueWithClaudeCode = async (_issue, projectDir, prompt, model, abort
163777
163772
  if (abortSignal?.aborted)
163778
163773
  return [];
163779
163774
  const status = await git.status();
163780
- const changedFiles = [
163781
- ...status.modified,
163782
- ...status.created,
163783
- ...status.not_added
163784
- ];
163775
+ const changedFiles = [...status.modified, ...status.created, ...status.not_added];
163785
163776
  return changedFiles.map((filePath) => ({
163786
163777
  filePath,
163787
163778
  newContent: fs4.readFileSync(path11.resolve(projectDir, filePath), "utf-8")
@@ -163826,6 +163817,7 @@ ${lastMessage?.content}` : lastMessage?.content;
163826
163817
  prompt,
163827
163818
  options: {
163828
163819
  cwd: projectDir,
163820
+ executable: "node",
163829
163821
  permissionMode: "bypassPermissions",
163830
163822
  systemPrompt: buildSystemPrompt(projectDir),
163831
163823
  maxTurns: 250,
@@ -166021,6 +166013,8 @@ var {
166021
166013
  } = import__.default;
166022
166014
 
166023
166015
  // src/cli/flags.ts
166016
+ import fs6 from "fs";
166017
+ import path13 from "path";
166024
166018
  import os5 from "os";
166025
166019
 
166026
166020
  // src/cli/profile.ts
@@ -166123,9 +166117,14 @@ function loadProfile(profileName, projectDir) {
166123
166117
  }
166124
166118
 
166125
166119
  // src/cli/flags.ts
166120
+ function getVersion() {
166121
+ const pkgPath = path13.resolve(import.meta.dirname, "..", "package.json");
166122
+ const pkg = JSON.parse(fs6.readFileSync(pkgPath, "utf-8"));
166123
+ return pkg.version;
166124
+ }
166126
166125
  function parseFlags(argv) {
166127
166126
  const program2 = new Command;
166128
- program2.name("multiplayer").description("Multiplayer debugging agent \u2014 automatically resolves issues using AI").version("0.0.1").option("--headless", "Run without TUI (structured log output, requires full config); also set via MULTIPLAYER_HEADLESS=true").option("--profile <name>", 'Config profile to use from .multiplayer/config (default: "default"); also set via MULTIPLAYER_PROFILE').option("--url <url>", "Multiplayer base API URL").option("--api-key <key>", "Multiplayer API key").option("--name <name>", "Agent name (defaults to hostname)").option("--dir <path>", "Project directory (must be a git repo)").option("--model <name>", "AI model name (e.g. claude-sonnet-4-6, gpt-4o)").option("--model-key <key>", "API key for the AI provider").option("--model-url <url>", "Optional base URL for OpenAI-compatible APIs").option("--max-concurrent <n>", "Maximum number of issues to resolve in parallel", String(DEFAULT_MAX_CONCURRENT)).option("--no-git-branch", "Work in current branch \u2014 no worktree, no new branch, no push").option("--health-port <port>", "Port for HTTP health check endpoint (headless mode only); also set via MULTIPLAYER_HEALTH_PORT").exitOverride();
166127
+ program2.name("multiplayer").description("Multiplayer debugging agent \u2014 automatically resolves issues using AI").version(getVersion()).option("--headless", "Run without TUI (structured log output, requires full config); also set via MULTIPLAYER_HEADLESS=true").option("--profile <name>", 'Config profile to use from .multiplayer/config (default: "default"); also set via MULTIPLAYER_PROFILE').option("--url <url>", "Multiplayer base API URL").option("--api-key <key>", "Multiplayer API key").option("--name <name>", "Agent name (defaults to hostname)").option("--dir <path>", "Project directory (must be a git repo)").option("--model <name>", "AI model name (e.g. claude-sonnet-4-6, gpt-4o)").option("--model-key <key>", "API key for the AI provider").option("--model-url <url>", "Optional base URL for OpenAI-compatible APIs").option("--max-concurrent <n>", "Maximum number of issues to resolve in parallel", String(DEFAULT_MAX_CONCURRENT)).option("--no-git-branch", "Work in current branch \u2014 no worktree, no new branch, no push").option("--health-port <port>", "Port for HTTP health check endpoint (headless mode only); also set via MULTIPLAYER_HEALTH_PORT").exitOverride();
166129
166128
  try {
166130
166129
  program2.parse(argv);
166131
166130
  } catch (err) {
@@ -166246,13 +166245,13 @@ var create2 = async (options, callback) => {
166246
166245
 
166247
166246
  // src/commands/sourcemaps/upload.ts
166248
166247
  var import_jsonwebtoken4 = __toESM(require_jsonwebtoken(), 1);
166249
- import fs6 from "fs";
166250
- import path13 from "path";
166248
+ import fs7 from "fs";
166249
+ import path14 from "path";
166251
166250
  var collectSourcemaps = (dir) => {
166252
- const entries = fs6.readdirSync(dir, { withFileTypes: true });
166251
+ const entries = fs7.readdirSync(dir, { withFileTypes: true });
166253
166252
  const files = [];
166254
166253
  for (const entry of entries) {
166255
- const fullPath = path13.join(dir, entry.name);
166254
+ const fullPath = path14.join(dir, entry.name);
166256
166255
  if (entry.isDirectory()) {
166257
166256
  files.push(...collectSourcemaps(fullPath));
166258
166257
  } else if (entry.isFile() && entry.name.endsWith(".map")) {
@@ -166273,7 +166272,7 @@ var upload = async (directories, options, callback) => {
166273
166272
  return callback(new Error(`No sourcemap files found in directories: ${directories.join(", ")}`), null);
166274
166273
  }
166275
166274
  for (const filePath of files) {
166276
- const stream = fs6.createReadStream(filePath);
166275
+ const stream = fs7.createReadStream(filePath);
166277
166276
  await uploadSourcemap(apiKey, jwtToken.workspace, jwtToken.project, releaseId, filePath, stream, baseUrl);
166278
166277
  }
166279
166278
  callback(null, { message: `Uploaded ${files.length} sourcemap(s) successfully` });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@multiplayer-app/cli",
3
- "version": "2.0.2",
3
+ "version": "2.0.4",
4
4
  "description": "Multiplayer CLI",
5
5
  "main": "dist/index.js",
6
6
  "bin": {