@synergenius/flow-weaver 0.8.1 → 0.8.2

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.
@@ -935,8 +935,8 @@ var require_command = __commonJS({
935
935
  "node_modules/commander/lib/command.js"(exports2) {
936
936
  var EventEmitter2 = __require("events").EventEmitter;
937
937
  var childProcess = __require("child_process");
938
- var path38 = __require("path");
939
- var fs37 = __require("fs");
938
+ var path39 = __require("path");
939
+ var fs38 = __require("fs");
940
940
  var process6 = __require("process");
941
941
  var { Argument: Argument2, humanReadableArgName } = require_argument();
942
942
  var { CommanderError: CommanderError2 } = require_error();
@@ -1759,10 +1759,10 @@ Expecting one of '${allowedValues.join("', '")}'`);
1759
1759
  let launchWithNode = false;
1760
1760
  const sourceExt = [".js", ".ts", ".tsx", ".mjs", ".cjs"];
1761
1761
  function findFile(baseDir, baseName) {
1762
- const localBin = path38.resolve(baseDir, baseName);
1763
- if (fs37.existsSync(localBin)) return localBin;
1764
- if (sourceExt.includes(path38.extname(baseName))) return void 0;
1765
- const foundExt = sourceExt.find((ext2) => fs37.existsSync(`${localBin}${ext2}`));
1762
+ const localBin = path39.resolve(baseDir, baseName);
1763
+ if (fs38.existsSync(localBin)) return localBin;
1764
+ if (sourceExt.includes(path39.extname(baseName))) return void 0;
1765
+ const foundExt = sourceExt.find((ext2) => fs38.existsSync(`${localBin}${ext2}`));
1766
1766
  if (foundExt) return `${localBin}${foundExt}`;
1767
1767
  return void 0;
1768
1768
  }
@@ -1773,23 +1773,23 @@ Expecting one of '${allowedValues.join("', '")}'`);
1773
1773
  if (this._scriptPath) {
1774
1774
  let resolvedScriptPath;
1775
1775
  try {
1776
- resolvedScriptPath = fs37.realpathSync(this._scriptPath);
1776
+ resolvedScriptPath = fs38.realpathSync(this._scriptPath);
1777
1777
  } catch (err) {
1778
1778
  resolvedScriptPath = this._scriptPath;
1779
1779
  }
1780
- executableDir = path38.resolve(path38.dirname(resolvedScriptPath), executableDir);
1780
+ executableDir = path39.resolve(path39.dirname(resolvedScriptPath), executableDir);
1781
1781
  }
1782
1782
  if (executableDir) {
1783
1783
  let localFile = findFile(executableDir, executableFile);
1784
1784
  if (!localFile && !subcommand._executableFile && this._scriptPath) {
1785
- const legacyName = path38.basename(this._scriptPath, path38.extname(this._scriptPath));
1785
+ const legacyName = path39.basename(this._scriptPath, path39.extname(this._scriptPath));
1786
1786
  if (legacyName !== this._name) {
1787
1787
  localFile = findFile(executableDir, `${legacyName}-${subcommand._name}`);
1788
1788
  }
1789
1789
  }
1790
1790
  executableFile = localFile || executableFile;
1791
1791
  }
1792
- launchWithNode = sourceExt.includes(path38.extname(executableFile));
1792
+ launchWithNode = sourceExt.includes(path39.extname(executableFile));
1793
1793
  let proc2;
1794
1794
  if (process6.platform !== "win32") {
1795
1795
  if (launchWithNode) {
@@ -2572,7 +2572,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
2572
2572
  * @return {Command}
2573
2573
  */
2574
2574
  nameFromFilename(filename) {
2575
- this._name = path38.basename(filename, path38.extname(filename));
2575
+ this._name = path39.basename(filename, path39.extname(filename));
2576
2576
  return this;
2577
2577
  }
2578
2578
  /**
@@ -2586,9 +2586,9 @@ Expecting one of '${allowedValues.join("', '")}'`);
2586
2586
  * @param {string} [path]
2587
2587
  * @return {string|null|Command}
2588
2588
  */
2589
- executableDir(path39) {
2590
- if (path39 === void 0) return this._executableDir;
2591
- this._executableDir = path39;
2589
+ executableDir(path40) {
2590
+ if (path40 === void 0) return this._executableDir;
2591
+ this._executableDir = path40;
2592
2592
  return this;
2593
2593
  }
2594
2594
  /**
@@ -6458,10 +6458,10 @@ var init_esm3 = __esm({
6458
6458
  * Return a void Promise that resolves once the stream ends.
6459
6459
  */
6460
6460
  async promise() {
6461
- return new Promise((resolve27, reject2) => {
6461
+ return new Promise((resolve28, reject2) => {
6462
6462
  this.on(DESTROYED, () => reject2(new Error("stream destroyed")));
6463
6463
  this.on("error", (er) => reject2(er));
6464
- this.on("end", () => resolve27());
6464
+ this.on("end", () => resolve28());
6465
6465
  });
6466
6466
  }
6467
6467
  /**
@@ -6485,7 +6485,7 @@ var init_esm3 = __esm({
6485
6485
  return Promise.resolve({ done: false, value: res });
6486
6486
  if (this[EOF])
6487
6487
  return stop();
6488
- let resolve27;
6488
+ let resolve28;
6489
6489
  let reject2;
6490
6490
  const onerr = (er) => {
6491
6491
  this.off("data", ondata);
@@ -6499,19 +6499,19 @@ var init_esm3 = __esm({
6499
6499
  this.off("end", onend);
6500
6500
  this.off(DESTROYED, ondestroy);
6501
6501
  this.pause();
6502
- resolve27({ value: value2, done: !!this[EOF] });
6502
+ resolve28({ value: value2, done: !!this[EOF] });
6503
6503
  };
6504
6504
  const onend = () => {
6505
6505
  this.off("error", onerr);
6506
6506
  this.off("data", ondata);
6507
6507
  this.off(DESTROYED, ondestroy);
6508
6508
  stop();
6509
- resolve27({ done: true, value: void 0 });
6509
+ resolve28({ done: true, value: void 0 });
6510
6510
  };
6511
6511
  const ondestroy = () => onerr(new Error("stream destroyed"));
6512
6512
  return new Promise((res2, rej) => {
6513
6513
  reject2 = rej;
6514
- resolve27 = res2;
6514
+ resolve28 = res2;
6515
6515
  this.once(DESTROYED, ondestroy);
6516
6516
  this.once("error", onerr);
6517
6517
  this.once("end", onend);
@@ -6886,12 +6886,12 @@ var init_esm4 = __esm({
6886
6886
  /**
6887
6887
  * Get the Path object referenced by the string path, resolved from this Path
6888
6888
  */
6889
- resolve(path38) {
6890
- if (!path38) {
6889
+ resolve(path39) {
6890
+ if (!path39) {
6891
6891
  return this;
6892
6892
  }
6893
- const rootPath = this.getRootString(path38);
6894
- const dir = path38.substring(rootPath.length);
6893
+ const rootPath = this.getRootString(path39);
6894
+ const dir = path39.substring(rootPath.length);
6895
6895
  const dirParts = dir.split(this.splitSep);
6896
6896
  const result = rootPath ? this.getRoot(rootPath).#resolveParts(dirParts) : this.#resolveParts(dirParts);
6897
6897
  return result;
@@ -7495,9 +7495,9 @@ var init_esm4 = __esm({
7495
7495
  if (this.#asyncReaddirInFlight) {
7496
7496
  await this.#asyncReaddirInFlight;
7497
7497
  } else {
7498
- let resolve27 = () => {
7498
+ let resolve28 = () => {
7499
7499
  };
7500
- this.#asyncReaddirInFlight = new Promise((res) => resolve27 = res);
7500
+ this.#asyncReaddirInFlight = new Promise((res) => resolve28 = res);
7501
7501
  try {
7502
7502
  for (const e of await this.#fs.promises.readdir(fullpath, {
7503
7503
  withFileTypes: true
@@ -7510,7 +7510,7 @@ var init_esm4 = __esm({
7510
7510
  children.provisional = 0;
7511
7511
  }
7512
7512
  this.#asyncReaddirInFlight = void 0;
7513
- resolve27();
7513
+ resolve28();
7514
7514
  }
7515
7515
  return children.slice(0, children.provisional);
7516
7516
  }
@@ -7643,8 +7643,8 @@ var init_esm4 = __esm({
7643
7643
  /**
7644
7644
  * @internal
7645
7645
  */
7646
- getRootString(path38) {
7647
- return win32.parse(path38).root;
7646
+ getRootString(path39) {
7647
+ return win32.parse(path39).root;
7648
7648
  }
7649
7649
  /**
7650
7650
  * @internal
@@ -7690,8 +7690,8 @@ var init_esm4 = __esm({
7690
7690
  /**
7691
7691
  * @internal
7692
7692
  */
7693
- getRootString(path38) {
7694
- return path38.startsWith("/") ? "/" : "";
7693
+ getRootString(path39) {
7694
+ return path39.startsWith("/") ? "/" : "";
7695
7695
  }
7696
7696
  /**
7697
7697
  * @internal
@@ -7740,8 +7740,8 @@ var init_esm4 = __esm({
7740
7740
  *
7741
7741
  * @internal
7742
7742
  */
7743
- constructor(cwd = process.cwd(), pathImpl, sep2, { nocase, childrenCacheSize = 16 * 1024, fs: fs37 = defaultFS } = {}) {
7744
- this.#fs = fsFromOption(fs37);
7743
+ constructor(cwd = process.cwd(), pathImpl, sep2, { nocase, childrenCacheSize = 16 * 1024, fs: fs38 = defaultFS } = {}) {
7744
+ this.#fs = fsFromOption(fs38);
7745
7745
  if (cwd instanceof URL || cwd.startsWith("file://")) {
7746
7746
  cwd = fileURLToPath(cwd);
7747
7747
  }
@@ -7780,11 +7780,11 @@ var init_esm4 = __esm({
7780
7780
  /**
7781
7781
  * Get the depth of a provided path, string, or the cwd
7782
7782
  */
7783
- depth(path38 = this.cwd) {
7784
- if (typeof path38 === "string") {
7785
- path38 = this.cwd.resolve(path38);
7783
+ depth(path39 = this.cwd) {
7784
+ if (typeof path39 === "string") {
7785
+ path39 = this.cwd.resolve(path39);
7786
7786
  }
7787
- return path38.depth();
7787
+ return path39.depth();
7788
7788
  }
7789
7789
  /**
7790
7790
  * Return the cache of child entries. Exposed so subclasses can create
@@ -8271,9 +8271,9 @@ var init_esm4 = __esm({
8271
8271
  process6();
8272
8272
  return results;
8273
8273
  }
8274
- chdir(path38 = this.cwd) {
8274
+ chdir(path39 = this.cwd) {
8275
8275
  const oldCwd = this.cwd;
8276
- this.cwd = typeof path38 === "string" ? this.cwd.resolve(path38) : path38;
8276
+ this.cwd = typeof path39 === "string" ? this.cwd.resolve(path39) : path39;
8277
8277
  this.cwd[setAsCwd](oldCwd);
8278
8278
  }
8279
8279
  };
@@ -8299,8 +8299,8 @@ var init_esm4 = __esm({
8299
8299
  /**
8300
8300
  * @internal
8301
8301
  */
8302
- newRoot(fs37) {
8303
- return new PathWin32(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs37 });
8302
+ newRoot(fs38) {
8303
+ return new PathWin32(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs38 });
8304
8304
  }
8305
8305
  /**
8306
8306
  * Return true if the provided path string is an absolute path
@@ -8328,8 +8328,8 @@ var init_esm4 = __esm({
8328
8328
  /**
8329
8329
  * @internal
8330
8330
  */
8331
- newRoot(fs37) {
8332
- return new PathPosix(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs37 });
8331
+ newRoot(fs38) {
8332
+ return new PathPosix(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs38 });
8333
8333
  }
8334
8334
  /**
8335
8335
  * Return true if the provided path string is an absolute path
@@ -8585,10 +8585,10 @@ var init_ignore = __esm({
8585
8585
  ignored(p) {
8586
8586
  const fullpath = p.fullpath();
8587
8587
  const fullpaths = `${fullpath}/`;
8588
- const relative5 = p.relative() || ".";
8589
- const relatives = `${relative5}/`;
8588
+ const relative6 = p.relative() || ".";
8589
+ const relatives = `${relative6}/`;
8590
8590
  for (const m of this.relative) {
8591
- if (m.match(relative5) || m.match(relatives))
8591
+ if (m.match(relative6) || m.match(relatives))
8592
8592
  return true;
8593
8593
  }
8594
8594
  for (const m of this.absolute) {
@@ -8599,9 +8599,9 @@ var init_ignore = __esm({
8599
8599
  }
8600
8600
  childrenIgnored(p) {
8601
8601
  const fullpath = p.fullpath() + "/";
8602
- const relative5 = (p.relative() || ".") + "/";
8602
+ const relative6 = (p.relative() || ".") + "/";
8603
8603
  for (const m of this.relativeChildren) {
8604
- if (m.match(relative5))
8604
+ if (m.match(relative6))
8605
8605
  return true;
8606
8606
  }
8607
8607
  for (const m of this.absoluteChildren) {
@@ -8648,8 +8648,8 @@ var init_processor = __esm({
8648
8648
  }
8649
8649
  // match, absolute, ifdir
8650
8650
  entries() {
8651
- return [...this.store.entries()].map(([path38, n]) => [
8652
- path38,
8651
+ return [...this.store.entries()].map(([path39, n]) => [
8652
+ path39,
8653
8653
  !!(n & 2),
8654
8654
  !!(n & 1)
8655
8655
  ]);
@@ -8862,9 +8862,9 @@ var init_walker = __esm({
8862
8862
  signal;
8863
8863
  maxDepth;
8864
8864
  includeChildMatches;
8865
- constructor(patterns, path38, opts) {
8865
+ constructor(patterns, path39, opts) {
8866
8866
  this.patterns = patterns;
8867
- this.path = path38;
8867
+ this.path = path39;
8868
8868
  this.opts = opts;
8869
8869
  this.#sep = !opts.posix && opts.platform === "win32" ? "\\" : "/";
8870
8870
  this.includeChildMatches = opts.includeChildMatches !== false;
@@ -8883,11 +8883,11 @@ var init_walker = __esm({
8883
8883
  });
8884
8884
  }
8885
8885
  }
8886
- #ignored(path38) {
8887
- return this.seen.has(path38) || !!this.#ignore?.ignored?.(path38);
8886
+ #ignored(path39) {
8887
+ return this.seen.has(path39) || !!this.#ignore?.ignored?.(path39);
8888
8888
  }
8889
- #childrenIgnored(path38) {
8890
- return !!this.#ignore?.childrenIgnored?.(path38);
8889
+ #childrenIgnored(path39) {
8890
+ return !!this.#ignore?.childrenIgnored?.(path39);
8891
8891
  }
8892
8892
  // backpressure mechanism
8893
8893
  pause() {
@@ -9102,8 +9102,8 @@ var init_walker = __esm({
9102
9102
  };
9103
9103
  GlobWalker = class extends GlobUtil {
9104
9104
  matches = /* @__PURE__ */ new Set();
9105
- constructor(patterns, path38, opts) {
9106
- super(patterns, path38, opts);
9105
+ constructor(patterns, path39, opts) {
9106
+ super(patterns, path39, opts);
9107
9107
  }
9108
9108
  matchEmit(e) {
9109
9109
  this.matches.add(e);
@@ -9140,8 +9140,8 @@ var init_walker = __esm({
9140
9140
  };
9141
9141
  GlobStream = class extends GlobUtil {
9142
9142
  results;
9143
- constructor(patterns, path38, opts) {
9144
- super(patterns, path38, opts);
9143
+ constructor(patterns, path39, opts) {
9144
+ super(patterns, path39, opts);
9145
9145
  this.results = new Minipass({
9146
9146
  signal: this.signal,
9147
9147
  objectMode: true
@@ -9741,7 +9741,7 @@ var require_util = __commonJS({
9741
9741
  var normalize2 = createSafeHandler((url2) => {
9742
9742
  });
9743
9743
  exports2.normalize = normalize2;
9744
- function join21(aRoot, aPath) {
9744
+ function join22(aRoot, aPath) {
9745
9745
  const pathType = getURLType(aPath);
9746
9746
  const rootType = getURLType(aRoot);
9747
9747
  aRoot = ensureDirectory(aRoot);
@@ -9771,12 +9771,12 @@ var require_util = __commonJS({
9771
9771
  const newPath = withBase(aPath, withBase(aRoot, base));
9772
9772
  return computeRelativeURL(base, newPath);
9773
9773
  }
9774
- exports2.join = join21;
9775
- function relative5(rootURL, targetURL) {
9774
+ exports2.join = join22;
9775
+ function relative6(rootURL, targetURL) {
9776
9776
  const result = relativeIfPossible(rootURL, targetURL);
9777
9777
  return typeof result === "string" ? result : normalize2(targetURL);
9778
9778
  }
9779
- exports2.relative = relative5;
9779
+ exports2.relative = relative6;
9780
9780
  function relativeIfPossible(rootURL, targetURL) {
9781
9781
  const urlType = getURLType(rootURL);
9782
9782
  if (urlType !== getURLType(targetURL)) {
@@ -9800,8 +9800,8 @@ var require_util = __commonJS({
9800
9800
  sourceURL = sourceURL.replace(/^\//, "");
9801
9801
  }
9802
9802
  let url2 = normalize2(sourceURL || "");
9803
- if (sourceRoot) url2 = join21(sourceRoot, url2);
9804
- if (sourceMapURL) url2 = join21(trimFilename(sourceMapURL), url2);
9803
+ if (sourceRoot) url2 = join22(sourceRoot, url2);
9804
+ if (sourceMapURL) url2 = join22(trimFilename(sourceMapURL), url2);
9805
9805
  return url2;
9806
9806
  }
9807
9807
  exports2.computeSourceURL = computeSourceURL;
@@ -10352,17 +10352,17 @@ var require_binary_search = __commonJS({
10352
10352
  var require_read_wasm = __commonJS({
10353
10353
  "node_modules/source-map/lib/read-wasm.js"(exports2, module2) {
10354
10354
  "use strict";
10355
- var fs37 = __require("fs");
10356
- var path38 = __require("path");
10355
+ var fs38 = __require("fs");
10356
+ var path39 = __require("path");
10357
10357
  module2.exports = function readWasm() {
10358
- return new Promise((resolve27, reject2) => {
10359
- const wasmPath = path38.join(__dirname, "mappings.wasm");
10360
- fs37.readFile(wasmPath, null, (error2, data) => {
10358
+ return new Promise((resolve28, reject2) => {
10359
+ const wasmPath = path39.join(__dirname, "mappings.wasm");
10360
+ fs38.readFile(wasmPath, null, (error2, data) => {
10361
10361
  if (error2) {
10362
10362
  reject2(error2);
10363
10363
  return;
10364
10364
  }
10365
- resolve27(data.buffer);
10365
+ resolve28(data.buffer);
10366
10366
  });
10367
10367
  });
10368
10368
  };
@@ -12589,13 +12589,13 @@ Add '@param ${fromPort}' to the workflow JSDoc and include it in the params obje
12589
12589
  connections.filter((c) => c.from.node === c.to.node).map((c) => c.from.node)
12590
12590
  );
12591
12591
  const nonSelfLoopConnections = connections.filter((c) => c.from.node !== c.to.node);
12592
- const dfs = (nodeName, path38) => {
12592
+ const dfs = (nodeName, path39) => {
12593
12593
  if (recursionStack.has(nodeName)) {
12594
12594
  if (selfLoopNodes.has(nodeName)) {
12595
12595
  return false;
12596
12596
  }
12597
- const cycleStart = path38.indexOf(nodeName);
12598
- const cyclePath = [...path38.slice(cycleStart), nodeName];
12597
+ const cycleStart = path39.indexOf(nodeName);
12598
+ const cyclePath = [...path39.slice(cycleStart), nodeName];
12599
12599
  const cycleNodes = cyclePath.slice(0, -1);
12600
12600
  const sortedCycle = [...cycleNodes].sort();
12601
12601
  const cycleKey = sortedCycle.join(",");
@@ -12617,7 +12617,7 @@ Add '@param ${fromPort}' to the workflow JSDoc and include it in the params obje
12617
12617
  return false;
12618
12618
  }
12619
12619
  recursionStack.add(nodeName);
12620
- const newPath = [...path38, nodeName];
12620
+ const newPath = [...path39, nodeName];
12621
12621
  const instance = instances.find((n) => n.id === nodeName);
12622
12622
  if (!instance) {
12623
12623
  recursionStack.delete(nodeName);
@@ -13351,15 +13351,15 @@ async function loadAST(filePath) {
13351
13351
  async function saveASTAlongside(ast) {
13352
13352
  const sourceFile = ast.sourceFile;
13353
13353
  const dir = path6.dirname(sourceFile);
13354
- const basename16 = path6.basename(sourceFile, path6.extname(sourceFile));
13355
- const astFile = path6.join(dir, `${basename16}.ast.json`);
13354
+ const basename17 = path6.basename(sourceFile, path6.extname(sourceFile));
13355
+ const astFile = path6.join(dir, `${basename17}.ast.json`);
13356
13356
  await saveAST(ast, astFile);
13357
13357
  return astFile;
13358
13358
  }
13359
13359
  async function loadASTAlongside(sourceFile) {
13360
13360
  const dir = path6.dirname(sourceFile);
13361
- const basename16 = path6.basename(sourceFile, path6.extname(sourceFile));
13362
- const astFile = path6.join(dir, `${basename16}.ast.json`);
13361
+ const basename17 = path6.basename(sourceFile, path6.extname(sourceFile));
13362
+ const astFile = path6.join(dir, `${basename17}.ast.json`);
13363
13363
  return loadAST(astFile);
13364
13364
  }
13365
13365
  var init_serialization_node = __esm({
@@ -14827,15 +14827,15 @@ var require_route = __commonJS({
14827
14827
  };
14828
14828
  }
14829
14829
  function wrapConversion(toModel, graph) {
14830
- const path38 = [graph[toModel].parent, toModel];
14830
+ const path39 = [graph[toModel].parent, toModel];
14831
14831
  let fn = conversions[graph[toModel].parent][toModel];
14832
14832
  let cur = graph[toModel].parent;
14833
14833
  while (graph[cur].parent) {
14834
- path38.unshift(graph[cur].parent);
14834
+ path39.unshift(graph[cur].parent);
14835
14835
  fn = link(conversions[graph[cur].parent][cur], fn);
14836
14836
  cur = graph[cur].parent;
14837
14837
  }
14838
- fn.conversion = path38;
14838
+ fn.conversion = path39;
14839
14839
  return fn;
14840
14840
  }
14841
14841
  module2.exports = function(fromModel) {
@@ -15316,7 +15316,7 @@ var require_lib4 = __commonJS({
15316
15316
  // node_modules/xmlhttprequest-ssl/lib/XMLHttpRequest.js
15317
15317
  var require_XMLHttpRequest = __commonJS({
15318
15318
  "node_modules/xmlhttprequest-ssl/lib/XMLHttpRequest.js"(exports2, module2) {
15319
- var fs37 = __require("fs");
15319
+ var fs38 = __require("fs");
15320
15320
  var Url = __require("url");
15321
15321
  var spawn2 = __require("child_process").spawn;
15322
15322
  module2.exports = XMLHttpRequest3;
@@ -15474,7 +15474,7 @@ var require_XMLHttpRequest = __commonJS({
15474
15474
  throw new Error("XMLHttpRequest: Only GET method is supported");
15475
15475
  }
15476
15476
  if (settings.async) {
15477
- fs37.readFile(unescape(url2.pathname), function(error2, data2) {
15477
+ fs38.readFile(unescape(url2.pathname), function(error2, data2) {
15478
15478
  if (error2) {
15479
15479
  self2.handleError(error2, error2.errno || -1);
15480
15480
  } else {
@@ -15486,7 +15486,7 @@ var require_XMLHttpRequest = __commonJS({
15486
15486
  });
15487
15487
  } else {
15488
15488
  try {
15489
- this.response = fs37.readFileSync(unescape(url2.pathname));
15489
+ this.response = fs38.readFileSync(unescape(url2.pathname));
15490
15490
  this.responseText = this.response.toString("utf8");
15491
15491
  this.status = 200;
15492
15492
  setState(self2.DONE);
@@ -15612,15 +15612,15 @@ var require_XMLHttpRequest = __commonJS({
15612
15612
  } else {
15613
15613
  var contentFile = ".node-xmlhttprequest-content-" + process.pid;
15614
15614
  var syncFile = ".node-xmlhttprequest-sync-" + process.pid;
15615
- fs37.writeFileSync(syncFile, "", "utf8");
15615
+ fs38.writeFileSync(syncFile, "", "utf8");
15616
15616
  var execString = "var http = require('http'), https = require('https'), fs = require('fs');var doRequest = http" + (ssl ? "s" : "") + ".request;var options = " + JSON.stringify(options) + ";var responseText = '';var responseData = Buffer.alloc(0);var req = doRequest(options, function(response) {response.on('data', function(chunk) { var data = Buffer.from(chunk); responseText += data.toString('utf8'); responseData = Buffer.concat([responseData, data]);});response.on('end', function() {fs.writeFileSync('" + contentFile + "', JSON.stringify({err: null, data: {statusCode: response.statusCode, headers: response.headers, text: responseText, data: responseData.toString('base64')}}), 'utf8');fs.unlinkSync('" + syncFile + "');});response.on('error', function(error) {fs.writeFileSync('" + contentFile + "', 'NODE-XMLHTTPREQUEST-ERROR:' + JSON.stringify(error), 'utf8');fs.unlinkSync('" + syncFile + "');});}).on('error', function(error) {fs.writeFileSync('" + contentFile + "', 'NODE-XMLHTTPREQUEST-ERROR:' + JSON.stringify(error), 'utf8');fs.unlinkSync('" + syncFile + "');});" + (data ? "req.write('" + JSON.stringify(data).slice(1, -1).replace(/'/g, "\\'") + "');" : "") + "req.end();";
15617
15617
  var syncProc = spawn2(process.argv[0], ["-e", execString]);
15618
15618
  var statusText;
15619
- while (fs37.existsSync(syncFile)) {
15619
+ while (fs38.existsSync(syncFile)) {
15620
15620
  }
15621
- self2.responseText = fs37.readFileSync(contentFile, "utf8");
15621
+ self2.responseText = fs38.readFileSync(contentFile, "utf8");
15622
15622
  syncProc.stdin.end();
15623
- fs37.unlinkSync(contentFile);
15623
+ fs38.unlinkSync(contentFile);
15624
15624
  if (self2.responseText.match(/^NODE-XMLHTTPREQUEST-ERROR:/)) {
15625
15625
  var errorObj = JSON.parse(self2.responseText.replace(/^NODE-XMLHTTPREQUEST-ERROR:/, ""));
15626
15626
  self2.handleError(errorObj, 503);
@@ -23000,7 +23000,7 @@ var require_compile = __commonJS({
23000
23000
  const schOrFunc = root2.refs[ref];
23001
23001
  if (schOrFunc)
23002
23002
  return schOrFunc;
23003
- let _sch = resolve27.call(this, root2, ref);
23003
+ let _sch = resolve28.call(this, root2, ref);
23004
23004
  if (_sch === void 0) {
23005
23005
  const schema2 = (_a = root2.localRefs) === null || _a === void 0 ? void 0 : _a[ref];
23006
23006
  const { schemaId } = this.opts;
@@ -23027,7 +23027,7 @@ var require_compile = __commonJS({
23027
23027
  function sameSchemaEnv(s1, s2) {
23028
23028
  return s1.schema === s2.schema && s1.root === s2.root && s1.baseId === s2.baseId;
23029
23029
  }
23030
- function resolve27(root2, ref) {
23030
+ function resolve28(root2, ref) {
23031
23031
  let sch;
23032
23032
  while (typeof (sch = this.refs[ref]) == "string")
23033
23033
  ref = sch;
@@ -23242,8 +23242,8 @@ var require_utils = __commonJS({
23242
23242
  }
23243
23243
  return ind;
23244
23244
  }
23245
- function removeDotSegments(path38) {
23246
- let input = path38;
23245
+ function removeDotSegments(path39) {
23246
+ let input = path39;
23247
23247
  const output = [];
23248
23248
  let nextSlash = -1;
23249
23249
  let len = 0;
@@ -23442,8 +23442,8 @@ var require_schemes = __commonJS({
23442
23442
  wsComponent.secure = void 0;
23443
23443
  }
23444
23444
  if (wsComponent.resourceName) {
23445
- const [path38, query] = wsComponent.resourceName.split("?");
23446
- wsComponent.path = path38 && path38 !== "/" ? path38 : void 0;
23445
+ const [path39, query] = wsComponent.resourceName.split("?");
23446
+ wsComponent.path = path39 && path39 !== "/" ? path39 : void 0;
23447
23447
  wsComponent.query = query;
23448
23448
  wsComponent.resourceName = void 0;
23449
23449
  }
@@ -23602,55 +23602,55 @@ var require_fast_uri = __commonJS({
23602
23602
  }
23603
23603
  return uri;
23604
23604
  }
23605
- function resolve27(baseURI, relativeURI, options) {
23605
+ function resolve28(baseURI, relativeURI, options) {
23606
23606
  const schemelessOptions = options ? Object.assign({ scheme: "null" }, options) : { scheme: "null" };
23607
23607
  const resolved = resolveComponent(parse7(baseURI, schemelessOptions), parse7(relativeURI, schemelessOptions), schemelessOptions, true);
23608
23608
  schemelessOptions.skipEscape = true;
23609
23609
  return serialize(resolved, schemelessOptions);
23610
23610
  }
23611
- function resolveComponent(base, relative5, options, skipNormalization) {
23611
+ function resolveComponent(base, relative6, options, skipNormalization) {
23612
23612
  const target = {};
23613
23613
  if (!skipNormalization) {
23614
23614
  base = parse7(serialize(base, options), options);
23615
- relative5 = parse7(serialize(relative5, options), options);
23615
+ relative6 = parse7(serialize(relative6, options), options);
23616
23616
  }
23617
23617
  options = options || {};
23618
- if (!options.tolerant && relative5.scheme) {
23619
- target.scheme = relative5.scheme;
23620
- target.userinfo = relative5.userinfo;
23621
- target.host = relative5.host;
23622
- target.port = relative5.port;
23623
- target.path = removeDotSegments(relative5.path || "");
23624
- target.query = relative5.query;
23618
+ if (!options.tolerant && relative6.scheme) {
23619
+ target.scheme = relative6.scheme;
23620
+ target.userinfo = relative6.userinfo;
23621
+ target.host = relative6.host;
23622
+ target.port = relative6.port;
23623
+ target.path = removeDotSegments(relative6.path || "");
23624
+ target.query = relative6.query;
23625
23625
  } else {
23626
- if (relative5.userinfo !== void 0 || relative5.host !== void 0 || relative5.port !== void 0) {
23627
- target.userinfo = relative5.userinfo;
23628
- target.host = relative5.host;
23629
- target.port = relative5.port;
23630
- target.path = removeDotSegments(relative5.path || "");
23631
- target.query = relative5.query;
23626
+ if (relative6.userinfo !== void 0 || relative6.host !== void 0 || relative6.port !== void 0) {
23627
+ target.userinfo = relative6.userinfo;
23628
+ target.host = relative6.host;
23629
+ target.port = relative6.port;
23630
+ target.path = removeDotSegments(relative6.path || "");
23631
+ target.query = relative6.query;
23632
23632
  } else {
23633
- if (!relative5.path) {
23633
+ if (!relative6.path) {
23634
23634
  target.path = base.path;
23635
- if (relative5.query !== void 0) {
23636
- target.query = relative5.query;
23635
+ if (relative6.query !== void 0) {
23636
+ target.query = relative6.query;
23637
23637
  } else {
23638
23638
  target.query = base.query;
23639
23639
  }
23640
23640
  } else {
23641
- if (relative5.path[0] === "/") {
23642
- target.path = removeDotSegments(relative5.path);
23641
+ if (relative6.path[0] === "/") {
23642
+ target.path = removeDotSegments(relative6.path);
23643
23643
  } else {
23644
23644
  if ((base.userinfo !== void 0 || base.host !== void 0 || base.port !== void 0) && !base.path) {
23645
- target.path = "/" + relative5.path;
23645
+ target.path = "/" + relative6.path;
23646
23646
  } else if (!base.path) {
23647
- target.path = relative5.path;
23647
+ target.path = relative6.path;
23648
23648
  } else {
23649
- target.path = base.path.slice(0, base.path.lastIndexOf("/") + 1) + relative5.path;
23649
+ target.path = base.path.slice(0, base.path.lastIndexOf("/") + 1) + relative6.path;
23650
23650
  }
23651
23651
  target.path = removeDotSegments(target.path);
23652
23652
  }
23653
- target.query = relative5.query;
23653
+ target.query = relative6.query;
23654
23654
  }
23655
23655
  target.userinfo = base.userinfo;
23656
23656
  target.host = base.host;
@@ -23658,7 +23658,7 @@ var require_fast_uri = __commonJS({
23658
23658
  }
23659
23659
  target.scheme = base.scheme;
23660
23660
  }
23661
- target.fragment = relative5.fragment;
23661
+ target.fragment = relative6.fragment;
23662
23662
  return target;
23663
23663
  }
23664
23664
  function equal(uriA, uriB, options) {
@@ -23829,7 +23829,7 @@ var require_fast_uri = __commonJS({
23829
23829
  var fastUri = {
23830
23830
  SCHEMES,
23831
23831
  normalize: normalize2,
23832
- resolve: resolve27,
23832
+ resolve: resolve28,
23833
23833
  resolveComponent,
23834
23834
  equal,
23835
23835
  serialize,
@@ -26805,12 +26805,12 @@ var require_dist = __commonJS({
26805
26805
  throw new Error(`Unknown format "${name}"`);
26806
26806
  return f;
26807
26807
  };
26808
- function addFormats(ajv, list, fs37, exportName) {
26808
+ function addFormats(ajv, list, fs38, exportName) {
26809
26809
  var _a;
26810
26810
  var _b;
26811
26811
  (_a = (_b = ajv.opts.code).formats) !== null && _a !== void 0 ? _a : _b.formats = (0, codegen_1._)`require("ajv-formats/dist/formats").${exportName}`;
26812
26812
  for (const f of list)
26813
- ajv.addFormat(f, fs37[f]);
26813
+ ajv.addFormat(f, fs38[f]);
26814
26814
  }
26815
26815
  module2.exports = exports2 = formatsPlugin;
26816
26816
  Object.defineProperty(exports2, "__esModule", { value: true });
@@ -30319,7 +30319,7 @@ function generateCode(ast, options) {
30319
30319
  if (sourceMapGenerator && ast.sourceFile) {
30320
30320
  try {
30321
30321
  const sourceContent = fs2.readFileSync(ast.sourceFile, "utf-8");
30322
- const sourceLines = sourceContent.split("\n");
30322
+ const sourceLines = sourceContent.split(/\r?\n/);
30323
30323
  const exportLineIndex = sourceLines.findIndex(
30324
30324
  (line) => line.includes(`export`) && line.includes(`function ${ast.functionName}`)
30325
30325
  );
@@ -30472,9 +30472,9 @@ function shouldUseStepTag(portName, port) {
30472
30472
 
30473
30473
  // src/sugar-optimizer.ts
30474
30474
  init_constants();
30475
- function validatePathMacro(path38, connections, instances) {
30475
+ function validatePathMacro(path39, connections, instances) {
30476
30476
  const instanceIds = new Set(instances.map((inst) => inst.id));
30477
- for (const step of path38.steps) {
30477
+ for (const step of path39.steps) {
30478
30478
  if (step.node === "Start" || step.node === "Exit") continue;
30479
30479
  if (!instanceIds.has(step.node)) return false;
30480
30480
  }
@@ -30484,9 +30484,9 @@ function validatePathMacro(path38, connections, instances) {
30484
30484
  connKeys.add(`${conn.from.node}.${conn.from.port}->${conn.to.node}.${conn.to.port}`);
30485
30485
  }
30486
30486
  }
30487
- for (let i = 0; i < path38.steps.length - 1; i++) {
30488
- const current2 = path38.steps[i];
30489
- const next = path38.steps[i + 1];
30487
+ for (let i = 0; i < path39.steps.length - 1; i++) {
30488
+ const current2 = path39.steps[i];
30489
+ const next = path39.steps[i + 1];
30490
30490
  const route = current2.route || "ok";
30491
30491
  let expectedKey;
30492
30492
  if (current2.node === "Start") {
@@ -30590,12 +30590,12 @@ function detectSugarPatterns(connections, instances, existingMacros, nodeTypes,
30590
30590
  }
30591
30591
  const candidateRoutes = [];
30592
30592
  const MAX_ROUTES = 20;
30593
- function dfs(node, path38, visited) {
30593
+ function dfs(node, path39, visited) {
30594
30594
  if (candidateRoutes.length >= MAX_ROUTES) return;
30595
30595
  if (node === "Exit") {
30596
- path38.push({ node: "Exit" });
30597
- candidateRoutes.push([...path38]);
30598
- path38.pop();
30596
+ path39.push({ node: "Exit" });
30597
+ candidateRoutes.push([...path39]);
30598
+ path39.pop();
30599
30599
  return;
30600
30600
  }
30601
30601
  if (visited.has(node)) return;
@@ -30607,15 +30607,15 @@ function detectSugarPatterns(connections, instances, existingMacros, nodeTypes,
30607
30607
  }
30608
30608
  if (edges.ok && !coveredByExistingMacro.has(edges.ok === "Exit" ? "" : edges.ok)) {
30609
30609
  const step = node === "Start" ? { node: "Start" } : { node };
30610
- path38.push(step);
30611
- dfs(edges.ok, path38, visited);
30612
- path38.pop();
30610
+ path39.push(step);
30611
+ dfs(edges.ok, path39, visited);
30612
+ path39.pop();
30613
30613
  }
30614
30614
  if (edges.fail && !coveredByExistingMacro.has(edges.fail === "Exit" ? "" : edges.fail)) {
30615
30615
  const step = { node, route: "fail" };
30616
- path38.push(step);
30617
- dfs(edges.fail, path38, visited);
30618
- path38.pop();
30616
+ path39.push(step);
30617
+ dfs(edges.fail, path39, visited);
30618
+ path39.pop();
30619
30619
  }
30620
30620
  visited.delete(node);
30621
30621
  }
@@ -33443,19 +33443,19 @@ function toKey(value2) {
33443
33443
  var toKey_default = toKey;
33444
33444
 
33445
33445
  // node_modules/lodash-es/_baseGet.js
33446
- function baseGet(object3, path38) {
33447
- path38 = castPath_default(path38, object3);
33448
- var index = 0, length = path38.length;
33446
+ function baseGet(object3, path39) {
33447
+ path39 = castPath_default(path39, object3);
33448
+ var index = 0, length = path39.length;
33449
33449
  while (object3 != null && index < length) {
33450
- object3 = object3[toKey_default(path38[index++])];
33450
+ object3 = object3[toKey_default(path39[index++])];
33451
33451
  }
33452
33452
  return index && index == length ? object3 : void 0;
33453
33453
  }
33454
33454
  var baseGet_default = baseGet;
33455
33455
 
33456
33456
  // node_modules/lodash-es/get.js
33457
- function get(object3, path38, defaultValue) {
33458
- var result = object3 == null ? void 0 : baseGet_default(object3, path38);
33457
+ function get(object3, path39, defaultValue) {
33458
+ var result = object3 == null ? void 0 : baseGet_default(object3, path39);
33459
33459
  return result === void 0 ? defaultValue : result;
33460
33460
  }
33461
33461
  var get_default = get;
@@ -34367,11 +34367,11 @@ function baseHasIn(object3, key) {
34367
34367
  var baseHasIn_default = baseHasIn;
34368
34368
 
34369
34369
  // node_modules/lodash-es/_hasPath.js
34370
- function hasPath(object3, path38, hasFunc) {
34371
- path38 = castPath_default(path38, object3);
34372
- var index = -1, length = path38.length, result = false;
34370
+ function hasPath(object3, path39, hasFunc) {
34371
+ path39 = castPath_default(path39, object3);
34372
+ var index = -1, length = path39.length, result = false;
34373
34373
  while (++index < length) {
34374
- var key = toKey_default(path38[index]);
34374
+ var key = toKey_default(path39[index]);
34375
34375
  if (!(result = object3 != null && hasFunc(object3, key))) {
34376
34376
  break;
34377
34377
  }
@@ -34386,21 +34386,21 @@ function hasPath(object3, path38, hasFunc) {
34386
34386
  var hasPath_default = hasPath;
34387
34387
 
34388
34388
  // node_modules/lodash-es/hasIn.js
34389
- function hasIn(object3, path38) {
34390
- return object3 != null && hasPath_default(object3, path38, baseHasIn_default);
34389
+ function hasIn(object3, path39) {
34390
+ return object3 != null && hasPath_default(object3, path39, baseHasIn_default);
34391
34391
  }
34392
34392
  var hasIn_default = hasIn;
34393
34393
 
34394
34394
  // node_modules/lodash-es/_baseMatchesProperty.js
34395
34395
  var COMPARE_PARTIAL_FLAG6 = 1;
34396
34396
  var COMPARE_UNORDERED_FLAG4 = 2;
34397
- function baseMatchesProperty(path38, srcValue) {
34398
- if (isKey_default(path38) && isStrictComparable_default(srcValue)) {
34399
- return matchesStrictComparable_default(toKey_default(path38), srcValue);
34397
+ function baseMatchesProperty(path39, srcValue) {
34398
+ if (isKey_default(path39) && isStrictComparable_default(srcValue)) {
34399
+ return matchesStrictComparable_default(toKey_default(path39), srcValue);
34400
34400
  }
34401
34401
  return function(object3) {
34402
- var objValue = get_default(object3, path38);
34403
- return objValue === void 0 && objValue === srcValue ? hasIn_default(object3, path38) : baseIsEqual_default(srcValue, objValue, COMPARE_PARTIAL_FLAG6 | COMPARE_UNORDERED_FLAG4);
34402
+ var objValue = get_default(object3, path39);
34403
+ return objValue === void 0 && objValue === srcValue ? hasIn_default(object3, path39) : baseIsEqual_default(srcValue, objValue, COMPARE_PARTIAL_FLAG6 | COMPARE_UNORDERED_FLAG4);
34404
34404
  };
34405
34405
  }
34406
34406
  var baseMatchesProperty_default = baseMatchesProperty;
@@ -34414,16 +34414,16 @@ function baseProperty(key) {
34414
34414
  var baseProperty_default = baseProperty;
34415
34415
 
34416
34416
  // node_modules/lodash-es/_basePropertyDeep.js
34417
- function basePropertyDeep(path38) {
34417
+ function basePropertyDeep(path39) {
34418
34418
  return function(object3) {
34419
- return baseGet_default(object3, path38);
34419
+ return baseGet_default(object3, path39);
34420
34420
  };
34421
34421
  }
34422
34422
  var basePropertyDeep_default = basePropertyDeep;
34423
34423
 
34424
34424
  // node_modules/lodash-es/property.js
34425
- function property(path38) {
34426
- return isKey_default(path38) ? baseProperty_default(toKey_default(path38)) : basePropertyDeep_default(path38);
34425
+ function property(path39) {
34426
+ return isKey_default(path39) ? baseProperty_default(toKey_default(path39)) : basePropertyDeep_default(path39);
34427
34427
  }
34428
34428
  var property_default = property;
34429
34429
 
@@ -34791,8 +34791,8 @@ function baseHas(object3, key) {
34791
34791
  var baseHas_default = baseHas;
34792
34792
 
34793
34793
  // node_modules/lodash-es/has.js
34794
- function has(object3, path38) {
34795
- return object3 != null && hasPath_default(object3, path38, baseHas_default);
34794
+ function has(object3, path39) {
34795
+ return object3 != null && hasPath_default(object3, path39, baseHas_default);
34796
34796
  }
34797
34797
  var has_default = has;
34798
34798
 
@@ -34915,14 +34915,14 @@ function negate(predicate) {
34915
34915
  var negate_default = negate;
34916
34916
 
34917
34917
  // node_modules/lodash-es/_baseSet.js
34918
- function baseSet(object3, path38, value2, customizer) {
34918
+ function baseSet(object3, path39, value2, customizer) {
34919
34919
  if (!isObject_default(object3)) {
34920
34920
  return object3;
34921
34921
  }
34922
- path38 = castPath_default(path38, object3);
34923
- var index = -1, length = path38.length, lastIndex = length - 1, nested = object3;
34922
+ path39 = castPath_default(path39, object3);
34923
+ var index = -1, length = path39.length, lastIndex = length - 1, nested = object3;
34924
34924
  while (nested != null && ++index < length) {
34925
- var key = toKey_default(path38[index]), newValue = value2;
34925
+ var key = toKey_default(path39[index]), newValue = value2;
34926
34926
  if (key === "__proto__" || key === "constructor" || key === "prototype") {
34927
34927
  return object3;
34928
34928
  }
@@ -34930,7 +34930,7 @@ function baseSet(object3, path38, value2, customizer) {
34930
34930
  var objValue = nested[key];
34931
34931
  newValue = customizer ? customizer(objValue, key, nested) : void 0;
34932
34932
  if (newValue === void 0) {
34933
- newValue = isObject_default(objValue) ? objValue : isIndex_default(path38[index + 1]) ? [] : {};
34933
+ newValue = isObject_default(objValue) ? objValue : isIndex_default(path39[index + 1]) ? [] : {};
34934
34934
  }
34935
34935
  }
34936
34936
  assignValue_default(nested, key, newValue);
@@ -34944,9 +34944,9 @@ var baseSet_default = baseSet;
34944
34944
  function basePickBy(object3, paths, predicate) {
34945
34945
  var index = -1, length = paths.length, result = {};
34946
34946
  while (++index < length) {
34947
- var path38 = paths[index], value2 = baseGet_default(object3, path38);
34948
- if (predicate(value2, path38)) {
34949
- baseSet_default(result, castPath_default(path38, object3), value2);
34947
+ var path39 = paths[index], value2 = baseGet_default(object3, path39);
34948
+ if (predicate(value2, path39)) {
34949
+ baseSet_default(result, castPath_default(path39, object3), value2);
34950
34950
  }
34951
34951
  }
34952
34952
  return result;
@@ -34962,8 +34962,8 @@ function pickBy(object3, predicate) {
34962
34962
  return [prop];
34963
34963
  });
34964
34964
  predicate = baseIteratee_default(predicate);
34965
- return basePickBy_default(object3, props, function(value2, path38) {
34966
- return predicate(value2, path38[0]);
34965
+ return basePickBy_default(object3, props, function(value2, path39) {
34966
+ return predicate(value2, path39[0]);
34967
34967
  });
34968
34968
  }
34969
34969
  var pickBy_default = pickBy;
@@ -37462,12 +37462,12 @@ function assignCategoriesMapProp(tokenTypes) {
37462
37462
  singleAssignCategoriesToksMap([], currTokType);
37463
37463
  });
37464
37464
  }
37465
- function singleAssignCategoriesToksMap(path38, nextNode) {
37466
- forEach_default(path38, (pathNode) => {
37465
+ function singleAssignCategoriesToksMap(path39, nextNode) {
37466
+ forEach_default(path39, (pathNode) => {
37467
37467
  nextNode.categoryMatchesMap[pathNode.tokenTypeIdx] = true;
37468
37468
  });
37469
37469
  forEach_default(nextNode.CATEGORIES, (nextCategory) => {
37470
- const newPath = path38.concat(nextNode);
37470
+ const newPath = path39.concat(nextNode);
37471
37471
  if (!includes_default(newPath, nextCategory)) {
37472
37472
  singleAssignCategoriesToksMap(newPath, nextCategory);
37473
37473
  }
@@ -38311,10 +38311,10 @@ var GastRefResolverVisitor = class extends GAstVisitor {
38311
38311
 
38312
38312
  // node_modules/chevrotain/lib/src/parse/grammar/interpreter.js
38313
38313
  var AbstractNextPossibleTokensWalker = class extends RestWalker {
38314
- constructor(topProd, path38) {
38314
+ constructor(topProd, path39) {
38315
38315
  super();
38316
38316
  this.topProd = topProd;
38317
- this.path = path38;
38317
+ this.path = path39;
38318
38318
  this.possibleTokTypes = [];
38319
38319
  this.nextProductionName = "";
38320
38320
  this.nextProductionOccurrence = 0;
@@ -38358,9 +38358,9 @@ var AbstractNextPossibleTokensWalker = class extends RestWalker {
38358
38358
  }
38359
38359
  };
38360
38360
  var NextAfterTokenWalker = class extends AbstractNextPossibleTokensWalker {
38361
- constructor(topProd, path38) {
38362
- super(topProd, path38);
38363
- this.path = path38;
38361
+ constructor(topProd, path39) {
38362
+ super(topProd, path39);
38363
+ this.path = path39;
38364
38364
  this.nextTerminalName = "";
38365
38365
  this.nextTerminalOccurrence = 0;
38366
38366
  this.nextTerminalName = this.path.lastTok.name;
@@ -38956,10 +38956,10 @@ function initializeArrayOfArrays(size) {
38956
38956
  }
38957
38957
  return result;
38958
38958
  }
38959
- function pathToHashKeys(path38) {
38959
+ function pathToHashKeys(path39) {
38960
38960
  let keys2 = [""];
38961
- for (let i = 0; i < path38.length; i++) {
38962
- const tokType = path38[i];
38961
+ for (let i = 0; i < path39.length; i++) {
38962
+ const tokType = path39[i];
38963
38963
  const longerKeys = [];
38964
38964
  for (let j = 0; j < keys2.length; j++) {
38965
38965
  const currShorterKey = keys2[j];
@@ -39198,7 +39198,7 @@ function validateRuleIsOverridden(ruleName, definedRulesNames, className) {
39198
39198
  }
39199
39199
  return errors2;
39200
39200
  }
39201
- function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path38 = []) {
39201
+ function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path39 = []) {
39202
39202
  const errors2 = [];
39203
39203
  const nextNonTerminals = getFirstNoneTerminal(currRule.definition);
39204
39204
  if (isEmpty_default(nextNonTerminals)) {
@@ -39210,15 +39210,15 @@ function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path38 = [])
39210
39210
  errors2.push({
39211
39211
  message: errMsgProvider.buildLeftRecursionError({
39212
39212
  topLevelRule: topRule,
39213
- leftRecursionPath: path38
39213
+ leftRecursionPath: path39
39214
39214
  }),
39215
39215
  type: ParserDefinitionErrorType.LEFT_RECURSION,
39216
39216
  ruleName
39217
39217
  });
39218
39218
  }
39219
- const validNextSteps = difference_default(nextNonTerminals, path38.concat([topRule]));
39219
+ const validNextSteps = difference_default(nextNonTerminals, path39.concat([topRule]));
39220
39220
  const errorsFromNextSteps = flatMap_default(validNextSteps, (currRefRule) => {
39221
- const newPath = clone_default(path38);
39221
+ const newPath = clone_default(path39);
39222
39222
  newPath.push(currRefRule);
39223
39223
  return validateNoLeftRecursion(topRule, currRefRule, errMsgProvider, newPath);
39224
39224
  });
@@ -46740,7 +46740,7 @@ ${fn.getText()}` : fn.getText();
46740
46740
  missingLines.push(...connectionLines);
46741
46741
  }
46742
46742
  if (missingLines.length === 0) return null;
46743
- const lines2 = content.split("\n");
46743
+ const lines2 = content.split(/\r?\n/);
46744
46744
  let jsDocEndLine = -1;
46745
46745
  for (let i = fnStartLine - 1; i >= 0; i--) {
46746
46746
  if (lines2[i].includes("*/")) {
@@ -46756,7 +46756,7 @@ ${fn.getText()}` : fn.getText();
46756
46756
  replaceLinesCount: 0
46757
46757
  };
46758
46758
  }
46759
- const lines = content.split("\n");
46759
+ const lines = content.split(/\r?\n/);
46760
46760
  const cursorLineText = lines[cursorLine] || "";
46761
46761
  if (/^\s*\/\*\*\s*$/.test(cursorLineText)) {
46762
46762
  const continuationLines = [
@@ -47051,8 +47051,8 @@ ${errorMessages.join("\n")}`);
47051
47051
  }
47052
47052
  function getDefaultOutputFile(sourceFile) {
47053
47053
  const dir = path7.dirname(sourceFile);
47054
- const basename16 = path7.basename(sourceFile, ".ts");
47055
- return path7.join(dir, `${basename16}.generated.ts`);
47054
+ const basename17 = path7.basename(sourceFile, ".ts");
47055
+ return path7.join(dir, `${basename17}.generated.ts`);
47056
47056
  }
47057
47057
 
47058
47058
  // src/api/index.ts
@@ -47327,7 +47327,7 @@ function processResult(result, scope) {
47327
47327
  }
47328
47328
  return result !== NOTHING ? result : void 0;
47329
47329
  }
47330
- function finalize(rootScope, value2, path38) {
47330
+ function finalize(rootScope, value2, path39) {
47331
47331
  if (isFrozen(value2))
47332
47332
  return value2;
47333
47333
  const useStrictIteration = rootScope.immer_.shouldUseStrictIteration();
@@ -47335,7 +47335,7 @@ function finalize(rootScope, value2, path38) {
47335
47335
  if (!state) {
47336
47336
  each(
47337
47337
  value2,
47338
- (key, childValue) => finalizeProperty(rootScope, state, value2, key, childValue, path38),
47338
+ (key, childValue) => finalizeProperty(rootScope, state, value2, key, childValue, path39),
47339
47339
  useStrictIteration
47340
47340
  );
47341
47341
  return value2;
@@ -47365,16 +47365,16 @@ function finalize(rootScope, value2, path38) {
47365
47365
  result,
47366
47366
  key,
47367
47367
  childValue,
47368
- path38,
47368
+ path39,
47369
47369
  isSet22
47370
47370
  ),
47371
47371
  useStrictIteration
47372
47372
  );
47373
47373
  maybeFreeze(rootScope, result, false);
47374
- if (path38 && rootScope.patches_) {
47374
+ if (path39 && rootScope.patches_) {
47375
47375
  getPlugin("Patches").generatePatches_(
47376
47376
  state,
47377
- path38,
47377
+ path39,
47378
47378
  rootScope.patches_,
47379
47379
  rootScope.inversePatches_
47380
47380
  );
@@ -47396,9 +47396,9 @@ function finalizeProperty(rootScope, parentState, targetObject, prop, childValue
47396
47396
  if (process.env.NODE_ENV !== "production" && childValue === targetObject)
47397
47397
  die(5);
47398
47398
  if (isDraft(childValue)) {
47399
- const path38 = rootPath && parentState && parentState.type_ !== 3 && // Set objects are atomic since they have no keys.
47399
+ const path39 = rootPath && parentState && parentState.type_ !== 3 && // Set objects are atomic since they have no keys.
47400
47400
  !has2(parentState.assigned_, prop) ? rootPath.concat(prop) : void 0;
47401
- const res = finalize(rootScope, childValue, path38);
47401
+ const res = finalize(rootScope, childValue, path39);
47402
47402
  set(targetObject, prop, res);
47403
47403
  if (isDraft(res)) {
47404
47404
  rootScope.canAutoFreeze_ = false;
@@ -58122,7 +58122,7 @@ function insertIntoFile(filePath, content, line) {
58122
58122
  return;
58123
58123
  }
58124
58124
  const existingContent = fs10.readFileSync(filePath, "utf8");
58125
- const lines = existingContent.split("\n");
58125
+ const lines = existingContent.split(/\r?\n/);
58126
58126
  if (line !== void 0 && line > 0) {
58127
58127
  const insertIndex = Math.min(line, lines.length);
58128
58128
  lines.splice(insertIndex, 0, content);
@@ -58259,17 +58259,17 @@ function buildAdjacency(ast) {
58259
58259
  function enumeratePaths(ast) {
58260
58260
  const { fromStart, toExit, edges } = buildAdjacency(ast);
58261
58261
  const paths = [];
58262
- function dfs(current2, path38, visited) {
58262
+ function dfs(current2, path39, visited) {
58263
58263
  if (toExit.has(current2)) {
58264
- paths.push([...path38, "Exit"]);
58264
+ paths.push([...path39, "Exit"]);
58265
58265
  }
58266
58266
  const targets = edges.get(current2) || [];
58267
58267
  for (const next of targets) {
58268
58268
  if (!visited.has(next)) {
58269
58269
  visited.add(next);
58270
- path38.push(next);
58271
- dfs(next, path38, visited);
58272
- path38.pop();
58270
+ path39.push(next);
58271
+ dfs(next, path39, visited);
58272
+ path39.pop();
58273
58273
  visited.delete(next);
58274
58274
  }
58275
58275
  }
@@ -58283,22 +58283,22 @@ function enumeratePaths(ast) {
58283
58283
  function buildGraph(ast) {
58284
58284
  const { fromStart, toExit, edges } = buildAdjacency(ast);
58285
58285
  const lines = [];
58286
- function dfs(current2, path38, visited) {
58286
+ function dfs(current2, path39, visited) {
58287
58287
  if (toExit.has(current2)) {
58288
- lines.push([...path38, "Exit"].join(" -> "));
58288
+ lines.push([...path39, "Exit"].join(" -> "));
58289
58289
  }
58290
58290
  const targets = edges.get(current2) || [];
58291
58291
  for (const next of targets) {
58292
58292
  if (!visited.has(next)) {
58293
58293
  visited.add(next);
58294
- path38.push(next);
58295
- dfs(next, path38, visited);
58296
- path38.pop();
58294
+ path39.push(next);
58295
+ dfs(next, path39, visited);
58296
+ path39.pop();
58297
58297
  visited.delete(next);
58298
58298
  }
58299
58299
  }
58300
58300
  if (targets.length === 0 && !toExit.has(current2)) {
58301
- lines.push(path38.join(" -> "));
58301
+ lines.push(path39.join(" -> "));
58302
58302
  }
58303
58303
  }
58304
58304
  fromStart.forEach((startNode) => {
@@ -59209,14 +59209,14 @@ function waypointsToSvgPath(waypoints, cornerRadius) {
59209
59209
  radii[i + 1] *= scale;
59210
59210
  }
59211
59211
  }
59212
- let path38 = `M ${waypoints[0][0]},${waypoints[0][1]}`;
59212
+ let path39 = `M ${waypoints[0][0]},${waypoints[0][1]}`;
59213
59213
  for (let i = 1; i < waypoints.length - 1; i++) {
59214
59214
  const prev = waypoints[i - 1];
59215
59215
  const curr = waypoints[i];
59216
59216
  const next = waypoints[i + 1];
59217
59217
  const r = radii[i];
59218
59218
  if (r < 2) {
59219
- path38 += ` L ${curr[0]},${curr[1]}`;
59219
+ path39 += ` L ${curr[0]},${curr[1]}`;
59220
59220
  continue;
59221
59221
  }
59222
59222
  const dPrev = [prev[0] - curr[0], prev[1] - curr[1]];
@@ -59229,12 +59229,12 @@ function waypointsToSvgPath(waypoints, cornerRadius) {
59229
59229
  const arcEnd = [curr[0] + uNext[0] * r, curr[1] + uNext[1] * r];
59230
59230
  const cross = dPrev[0] * dNext[1] - dPrev[1] * dNext[0];
59231
59231
  const sweep = cross > 0 ? 0 : 1;
59232
- path38 += ` L ${arcStart[0]},${arcStart[1]}`;
59233
- path38 += ` A ${r} ${r} 0 0 ${sweep} ${arcEnd[0]},${arcEnd[1]}`;
59232
+ path39 += ` L ${arcStart[0]},${arcStart[1]}`;
59233
+ path39 += ` A ${r} ${r} 0 0 ${sweep} ${arcEnd[0]},${arcEnd[1]}`;
59234
59234
  }
59235
59235
  const last2 = waypoints[waypoints.length - 1];
59236
- path38 += ` L ${last2[0]},${last2[1]}`;
59237
- return path38;
59236
+ path39 += ` L ${last2[0]},${last2[1]}`;
59237
+ return path39;
59238
59238
  }
59239
59239
  function computeWaypoints(from, to, nodeBoxes, sourceNodeId, targetNodeId, padding, exitStub, entryStub, allocator) {
59240
59240
  const isSelfConnection = sourceNodeId === targetNodeId;
@@ -59381,7 +59381,7 @@ function calculateOrthogonalPath(from, to, nodeBoxes, sourceNodeId, targetNodeId
59381
59381
  }
59382
59382
  function calculateOrthogonalPathSafe(from, to, nodeBoxes, sourceNodeId, targetNodeId, options, allocator) {
59383
59383
  try {
59384
- const path38 = calculateOrthogonalPath(
59384
+ const path39 = calculateOrthogonalPath(
59385
59385
  from,
59386
59386
  to,
59387
59387
  nodeBoxes,
@@ -59390,8 +59390,8 @@ function calculateOrthogonalPathSafe(from, to, nodeBoxes, sourceNodeId, targetNo
59390
59390
  options,
59391
59391
  allocator
59392
59392
  );
59393
- if (!path38 || path38.length < 5) return null;
59394
- return path38;
59393
+ if (!path39 || path39.length < 5) return null;
59394
+ return path39;
59395
59395
  } catch {
59396
59396
  return null;
59397
59397
  }
@@ -59586,13 +59586,13 @@ function computeConnectionPath(sx, sy, tx, ty) {
59586
59586
  const deUy = deY / deLen;
59587
59587
  const [cx, cy] = quadCurveControl(bx, by, dx, dy, -deUx, -deUy);
59588
59588
  const [fx, fy] = quadCurveControl(gx, gy, ex, ey, deUx, deUy);
59589
- let path38 = `M ${cx},${cy} M ${ax},${ay}`;
59590
- path38 += ` L ${bx},${by}`;
59591
- path38 += ` Q ${cx},${cy} ${dx},${dy}`;
59592
- path38 += ` L ${ex},${ey}`;
59593
- path38 += ` Q ${fx},${fy} ${gx},${gy}`;
59594
- path38 += ` L ${hx},${hy}`;
59595
- return path38;
59589
+ let path39 = `M ${cx},${cy} M ${ax},${ay}`;
59590
+ path39 += ` L ${bx},${by}`;
59591
+ path39 += ` Q ${cx},${cy} ${dx},${dy}`;
59592
+ path39 += ` L ${ex},${ey}`;
59593
+ path39 += ` Q ${fx},${fy} ${gx},${gy}`;
59594
+ path39 += ` L ${hx},${hy}`;
59595
+ return path39;
59596
59596
  }
59597
59597
  function orderedPorts(ports, direction) {
59598
59598
  const cloned = {};
@@ -59880,7 +59880,7 @@ function finalizeScopePositions(parentNode, ast, theme = "dark") {
59880
59880
  function buildConnection(fromNode, fromPort, toNode, toPort, sourcePort, targetPort, theme = "dark") {
59881
59881
  const sourceColor = getPortColor(sourcePort.dataType, sourcePort.isFailure, theme);
59882
59882
  const targetColor = getPortColor(targetPort.dataType, targetPort.isFailure, theme);
59883
- const path38 = computeConnectionPath(sourcePort.cx, sourcePort.cy, targetPort.cx, targetPort.cy);
59883
+ const path39 = computeConnectionPath(sourcePort.cx, sourcePort.cy, targetPort.cx, targetPort.cy);
59884
59884
  return {
59885
59885
  fromNode,
59886
59886
  fromPort,
@@ -59889,7 +59889,7 @@ function buildConnection(fromNode, fromPort, toNode, toPort, sourcePort, targetP
59889
59889
  sourceColor,
59890
59890
  targetColor,
59891
59891
  isStepConnection: sourcePort.dataType === "STEP",
59892
- path: path38
59892
+ path: path39
59893
59893
  };
59894
59894
  }
59895
59895
  function portsColumnHeight(count) {
@@ -60280,7 +60280,7 @@ function buildDiagramGraph(ast, options = {}) {
60280
60280
  const dy = ty - sy;
60281
60281
  const distance = Math.sqrt(dx * dx + dy * dy);
60282
60282
  const useCurve = forceCurveSet.has(pc);
60283
- let path38;
60283
+ let path39;
60284
60284
  if (!useCurve && distance > ORTHOGONAL_DISTANCE_THRESHOLD) {
60285
60285
  const orthoPath = calculateOrthogonalPathSafe(
60286
60286
  [sx, sy],
@@ -60291,9 +60291,9 @@ function buildDiagramGraph(ast, options = {}) {
60291
60291
  { fromPortIndex: pc.fromPortIndex, toPortIndex: pc.toPortIndex },
60292
60292
  allocator
60293
60293
  );
60294
- path38 = orthoPath ?? computeConnectionPath(sx, sy, tx, ty);
60294
+ path39 = orthoPath ?? computeConnectionPath(sx, sy, tx, ty);
60295
60295
  } else {
60296
- path38 = computeConnectionPath(sx, sy, tx, ty);
60296
+ path39 = computeConnectionPath(sx, sy, tx, ty);
60297
60297
  }
60298
60298
  const sourceColor = getPortColor(pc.sourcePort.dataType, pc.sourcePort.isFailure, themeName);
60299
60299
  const targetColor = getPortColor(pc.targetPort.dataType, pc.targetPort.isFailure, themeName);
@@ -60305,7 +60305,7 @@ function buildDiagramGraph(ast, options = {}) {
60305
60305
  sourceColor,
60306
60306
  targetColor,
60307
60307
  isStepConnection: pc.sourcePort.dataType === "STEP",
60308
- path: path38
60308
+ path: path39
60309
60309
  });
60310
60310
  }
60311
60311
  for (const node of nodes) {
@@ -60378,12 +60378,12 @@ function resolveDefaultIcon(nt) {
60378
60378
  if (nt.variant === "WORKFLOW" || nt.variant === "IMPORTED_WORKFLOW") return "flow";
60379
60379
  return "code";
60380
60380
  }
60381
- function pathExtent(path38) {
60381
+ function pathExtent(path39) {
60382
60382
  let minX = Infinity, minY = Infinity;
60383
60383
  let maxX = -Infinity, maxY = -Infinity;
60384
60384
  const pattern = /(-?[\d.]+),(-?[\d.]+)/g;
60385
60385
  let m;
60386
- while ((m = pattern.exec(path38)) !== null) {
60386
+ while ((m = pattern.exec(path39)) !== null) {
60387
60387
  const x = parseFloat(m[1]);
60388
60388
  const y = parseFloat(m[2]);
60389
60389
  minX = Math.min(minX, x);
@@ -63428,13 +63428,13 @@ var PromisePolyfill = class extends Promise {
63428
63428
  // Available starting from Node 22
63429
63429
  // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/withResolvers
63430
63430
  static withResolver() {
63431
- let resolve27;
63431
+ let resolve28;
63432
63432
  let reject2;
63433
63433
  const promise = new Promise((res, rej) => {
63434
- resolve27 = res;
63434
+ resolve28 = res;
63435
63435
  reject2 = rej;
63436
63436
  });
63437
- return { promise, resolve: resolve27, reject: reject2 };
63437
+ return { promise, resolve: resolve28, reject: reject2 };
63438
63438
  }
63439
63439
  };
63440
63440
 
@@ -63468,7 +63468,7 @@ function createPrompt(view) {
63468
63468
  output
63469
63469
  });
63470
63470
  const screen = new ScreenManager(rl);
63471
- const { promise, resolve: resolve27, reject: reject2 } = PromisePolyfill.withResolver();
63471
+ const { promise, resolve: resolve28, reject: reject2 } = PromisePolyfill.withResolver();
63472
63472
  const cancel = () => reject2(new CancelPromptError());
63473
63473
  if (signal) {
63474
63474
  const abort = () => reject2(new AbortPromptError({ cause: signal.reason }));
@@ -63495,7 +63495,7 @@ function createPrompt(view) {
63495
63495
  cycle(() => {
63496
63496
  try {
63497
63497
  const nextView = view(config2, (value2) => {
63498
- setImmediate(() => resolve27(value2));
63498
+ setImmediate(() => resolve28(value2));
63499
63499
  });
63500
63500
  if (nextView === void 0) {
63501
63501
  const callerFilename = callSites[1]?.getFileName();
@@ -64076,13 +64076,13 @@ var PromisePolyfill2 = class extends Promise {
64076
64076
  // Available starting from Node 22
64077
64077
  // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/withResolvers
64078
64078
  static withResolver() {
64079
- let resolve27;
64079
+ let resolve28;
64080
64080
  let reject2;
64081
64081
  const promise = new Promise((res, rej) => {
64082
- resolve27 = res;
64082
+ resolve28 = res;
64083
64083
  reject2 = rej;
64084
64084
  });
64085
- return { promise, resolve: resolve27, reject: reject2 };
64085
+ return { promise, resolve: resolve28, reject: reject2 };
64086
64086
  }
64087
64087
  };
64088
64088
 
@@ -64116,7 +64116,7 @@ function createPrompt2(view) {
64116
64116
  output
64117
64117
  });
64118
64118
  const screen = new ScreenManager2(rl);
64119
- const { promise, resolve: resolve27, reject: reject2 } = PromisePolyfill2.withResolver();
64119
+ const { promise, resolve: resolve28, reject: reject2 } = PromisePolyfill2.withResolver();
64120
64120
  const cancel = () => reject2(new CancelPromptError2());
64121
64121
  if (signal) {
64122
64122
  const abort = () => reject2(new AbortPromptError2({ cause: signal.reason }));
@@ -64143,7 +64143,7 @@ function createPrompt2(view) {
64143
64143
  cycle(() => {
64144
64144
  try {
64145
64145
  const nextView = view(config2, (value2) => {
64146
- setImmediate(() => resolve27(value2));
64146
+ setImmediate(() => resolve28(value2));
64147
64147
  });
64148
64148
  if (nextView === void 0) {
64149
64149
  const callerFilename = callSites[1]?.getFileName();
@@ -64695,13 +64695,13 @@ var PromisePolyfill3 = class extends Promise {
64695
64695
  // Available starting from Node 22
64696
64696
  // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/withResolvers
64697
64697
  static withResolver() {
64698
- let resolve27;
64698
+ let resolve28;
64699
64699
  let reject2;
64700
64700
  const promise = new Promise((res, rej) => {
64701
- resolve27 = res;
64701
+ resolve28 = res;
64702
64702
  reject2 = rej;
64703
64703
  });
64704
- return { promise, resolve: resolve27, reject: reject2 };
64704
+ return { promise, resolve: resolve28, reject: reject2 };
64705
64705
  }
64706
64706
  };
64707
64707
 
@@ -64735,7 +64735,7 @@ function createPrompt3(view) {
64735
64735
  output
64736
64736
  });
64737
64737
  const screen = new ScreenManager3(rl);
64738
- const { promise, resolve: resolve27, reject: reject2 } = PromisePolyfill3.withResolver();
64738
+ const { promise, resolve: resolve28, reject: reject2 } = PromisePolyfill3.withResolver();
64739
64739
  const cancel = () => reject2(new CancelPromptError3());
64740
64740
  if (signal) {
64741
64741
  const abort = () => reject2(new AbortPromptError3({ cause: signal.reason }));
@@ -64762,7 +64762,7 @@ function createPrompt3(view) {
64762
64762
  cycle(() => {
64763
64763
  try {
64764
64764
  const nextView = view(config2, (value2) => {
64765
- setImmediate(() => resolve27(value2));
64765
+ setImmediate(() => resolve28(value2));
64766
64766
  });
64767
64767
  if (nextView === void 0) {
64768
64768
  const callerFilename = callSites[1]?.getFileName();
@@ -65609,7 +65609,7 @@ async function watchCommand(input, options = {}) {
65609
65609
  process.exit(0);
65610
65610
  };
65611
65611
  process.on("SIGINT", cleanup);
65612
- process.on("SIGTERM", cleanup);
65612
+ if (process.platform !== "win32") process.on("SIGTERM", cleanup);
65613
65613
  await new Promise(() => {
65614
65614
  });
65615
65615
  }
@@ -65973,7 +65973,7 @@ async function runInngestDevMode(filePath, options) {
65973
65973
  };
65974
65974
  const stopServer = () => {
65975
65975
  if (serverProcess && !serverProcess.killed) {
65976
- serverProcess.kill("SIGTERM");
65976
+ serverProcess.kill();
65977
65977
  serverProcess = null;
65978
65978
  }
65979
65979
  };
@@ -66029,7 +66029,7 @@ async function runInngestDevMode(filePath, options) {
66029
66029
  process.exit(0);
66030
66030
  };
66031
66031
  process.on("SIGINT", cleanup);
66032
- process.on("SIGTERM", cleanup);
66032
+ if (process.platform !== "win32") process.on("SIGTERM", cleanup);
66033
66033
  await new Promise(() => {
66034
66034
  });
66035
66035
  }
@@ -66081,7 +66081,7 @@ async function devCommand(input, options = {}) {
66081
66081
  process.exit(0);
66082
66082
  };
66083
66083
  process.on("SIGINT", cleanup);
66084
- process.on("SIGTERM", cleanup);
66084
+ if (process.platform !== "win32") process.on("SIGTERM", cleanup);
66085
66085
  await new Promise(() => {
66086
66086
  });
66087
66087
  }
@@ -67261,12 +67261,12 @@ function parse4(str2) {
67261
67261
  uri.queryKey = queryKey(uri, uri["query"]);
67262
67262
  return uri;
67263
67263
  }
67264
- function pathNames(obj, path38) {
67265
- const regx = /\/{2,9}/g, names = path38.replace(regx, "/").split("/");
67266
- if (path38.slice(0, 1) == "/" || path38.length === 0) {
67264
+ function pathNames(obj, path39) {
67265
+ const regx = /\/{2,9}/g, names = path39.replace(regx, "/").split("/");
67266
+ if (path39.slice(0, 1) == "/" || path39.length === 0) {
67267
67267
  names.splice(0, 1);
67268
67268
  }
67269
- if (path38.slice(-1) == "/") {
67269
+ if (path39.slice(-1) == "/") {
67270
67270
  names.splice(names.length - 1, 1);
67271
67271
  }
67272
67272
  return names;
@@ -67884,7 +67884,7 @@ var protocol2 = Socket.protocol;
67884
67884
  // node_modules/socket.io-client/build/esm-debug/url.js
67885
67885
  var import_debug7 = __toESM(require_src(), 1);
67886
67886
  var debug7 = (0, import_debug7.default)("socket.io-client:url");
67887
- function url(uri, path38 = "", loc) {
67887
+ function url(uri, path39 = "", loc) {
67888
67888
  let obj = uri;
67889
67889
  loc = loc || typeof location !== "undefined" && location;
67890
67890
  if (null == uri)
@@ -67918,7 +67918,7 @@ function url(uri, path38 = "", loc) {
67918
67918
  obj.path = obj.path || "/";
67919
67919
  const ipv62 = obj.host.indexOf(":") !== -1;
67920
67920
  const host = ipv62 ? "[" + obj.host + "]" : obj.host;
67921
- obj.id = obj.protocol + "://" + host + ":" + obj.port + path38;
67921
+ obj.id = obj.protocol + "://" + host + ":" + obj.port + path39;
67922
67922
  obj.href = obj.protocol + "://" + host + (loc && loc.port === obj.port ? "" : ":" + obj.port);
67923
67923
  return obj;
67924
67924
  }
@@ -68570,9 +68570,9 @@ var Socket2 = class extends import_component_emitter5.Emitter {
68570
68570
  * @return a Promise that will be fulfilled when the server acknowledges the event
68571
68571
  */
68572
68572
  emitWithAck(ev, ...args) {
68573
- return new Promise((resolve27, reject2) => {
68573
+ return new Promise((resolve28, reject2) => {
68574
68574
  const fn = (arg1, arg2) => {
68575
- return arg1 ? reject2(arg1) : resolve27(arg2);
68575
+ return arg1 ? reject2(arg1) : resolve28(arg2);
68576
68576
  };
68577
68577
  fn.withError = true;
68578
68578
  args.push(fn);
@@ -69545,8 +69545,8 @@ function lookup(uri, opts) {
69545
69545
  const parsed = url(uri, opts.path || "/socket.io");
69546
69546
  const source = parsed.source;
69547
69547
  const id = parsed.id;
69548
- const path38 = parsed.path;
69549
- const sameNamespace = cache[id] && path38 in cache[id]["nsps"];
69548
+ const path39 = parsed.path;
69549
+ const sameNamespace = cache[id] && path39 in cache[id]["nsps"];
69550
69550
  const newConnection = opts.forceNew || opts["force new connection"] || false === opts.multiplex || sameNamespace;
69551
69551
  let io;
69552
69552
  if (newConnection) {
@@ -70090,8 +70090,8 @@ function getErrorMap() {
70090
70090
 
70091
70091
  // node_modules/zod/v3/helpers/parseUtil.js
70092
70092
  var makeIssue = (params) => {
70093
- const { data, path: path38, errorMaps, issueData } = params;
70094
- const fullPath = [...path38, ...issueData.path || []];
70093
+ const { data, path: path39, errorMaps, issueData } = params;
70094
+ const fullPath = [...path39, ...issueData.path || []];
70095
70095
  const fullIssue = {
70096
70096
  ...issueData,
70097
70097
  path: fullPath
@@ -70207,11 +70207,11 @@ var errorUtil;
70207
70207
 
70208
70208
  // node_modules/zod/v3/types.js
70209
70209
  var ParseInputLazyPath = class {
70210
- constructor(parent, value2, path38, key) {
70210
+ constructor(parent, value2, path39, key) {
70211
70211
  this._cachedPath = [];
70212
70212
  this.parent = parent;
70213
70213
  this.data = value2;
70214
- this._path = path38;
70214
+ this._path = path39;
70215
70215
  this._key = key;
70216
70216
  }
70217
70217
  get path() {
@@ -73848,10 +73848,10 @@ function assignProp(target, prop, value2) {
73848
73848
  configurable: true
73849
73849
  });
73850
73850
  }
73851
- function getElementAtPath(obj, path38) {
73852
- if (!path38)
73851
+ function getElementAtPath(obj, path39) {
73852
+ if (!path39)
73853
73853
  return obj;
73854
- return path38.reduce((acc, key) => acc?.[key], obj);
73854
+ return path39.reduce((acc, key) => acc?.[key], obj);
73855
73855
  }
73856
73856
  function promiseAllObject(promisesObj) {
73857
73857
  const keys2 = Object.keys(promisesObj);
@@ -74171,11 +74171,11 @@ function aborted(x, startIndex = 0) {
74171
74171
  }
74172
74172
  return false;
74173
74173
  }
74174
- function prefixIssues(path38, issues) {
74174
+ function prefixIssues(path39, issues) {
74175
74175
  return issues.map((iss) => {
74176
74176
  var _a;
74177
74177
  (_a = iss).path ?? (_a.path = []);
74178
- iss.path.unshift(path38);
74178
+ iss.path.unshift(path39);
74179
74179
  return iss;
74180
74180
  });
74181
74181
  }
@@ -81684,7 +81684,7 @@ var Protocol = class {
81684
81684
  return;
81685
81685
  }
81686
81686
  const pollInterval = task2.pollInterval ?? this._options?.defaultTaskPollInterval ?? 1e3;
81687
- await new Promise((resolve27) => setTimeout(resolve27, pollInterval));
81687
+ await new Promise((resolve28) => setTimeout(resolve28, pollInterval));
81688
81688
  options?.signal?.throwIfAborted();
81689
81689
  }
81690
81690
  } catch (error2) {
@@ -81701,7 +81701,7 @@ var Protocol = class {
81701
81701
  */
81702
81702
  request(request, resultSchema, options) {
81703
81703
  const { relatedRequestId, resumptionToken, onresumptiontoken, task, relatedTask } = options ?? {};
81704
- return new Promise((resolve27, reject2) => {
81704
+ return new Promise((resolve28, reject2) => {
81705
81705
  const earlyReject = (error2) => {
81706
81706
  reject2(error2);
81707
81707
  };
@@ -81779,7 +81779,7 @@ var Protocol = class {
81779
81779
  if (!parseResult.success) {
81780
81780
  reject2(parseResult.error);
81781
81781
  } else {
81782
- resolve27(parseResult.data);
81782
+ resolve28(parseResult.data);
81783
81783
  }
81784
81784
  } catch (error2) {
81785
81785
  reject2(error2);
@@ -82040,12 +82040,12 @@ var Protocol = class {
82040
82040
  }
82041
82041
  } catch {
82042
82042
  }
82043
- return new Promise((resolve27, reject2) => {
82043
+ return new Promise((resolve28, reject2) => {
82044
82044
  if (signal.aborted) {
82045
82045
  reject2(new McpError(ErrorCode.InvalidRequest, "Request cancelled"));
82046
82046
  return;
82047
82047
  }
82048
- const timeoutId = setTimeout(resolve27, interval);
82048
+ const timeoutId = setTimeout(resolve28, interval);
82049
82049
  signal.addEventListener("abort", () => {
82050
82050
  clearTimeout(timeoutId);
82051
82051
  reject2(new McpError(ErrorCode.InvalidRequest, "Request cancelled"));
@@ -83004,7 +83004,7 @@ var McpServer = class {
83004
83004
  let task = createTaskResult.task;
83005
83005
  const pollInterval = task.pollInterval ?? 5e3;
83006
83006
  while (task.status !== "completed" && task.status !== "failed" && task.status !== "cancelled") {
83007
- await new Promise((resolve27) => setTimeout(resolve27, pollInterval));
83007
+ await new Promise((resolve28) => setTimeout(resolve28, pollInterval));
83008
83008
  const updatedTask = await extra.taskStore.getTask(taskId);
83009
83009
  if (!updatedTask) {
83010
83010
  throw new McpError(ErrorCode.InternalError, `Task ${taskId} not found during polling`);
@@ -83647,12 +83647,12 @@ var StdioServerTransport = class {
83647
83647
  this.onclose?.();
83648
83648
  }
83649
83649
  send(message) {
83650
- return new Promise((resolve27) => {
83650
+ return new Promise((resolve28) => {
83651
83651
  const json2 = serializeMessage(message);
83652
83652
  if (this._stdout.write(json2)) {
83653
- resolve27();
83653
+ resolve28();
83654
83654
  } else {
83655
- this._stdout.once("drain", resolve27);
83655
+ this._stdout.once("drain", resolve28);
83656
83656
  }
83657
83657
  });
83658
83658
  }
@@ -83866,17 +83866,17 @@ var EditorConnection = class {
83866
83866
  return { requestId: "", success: false, error: "Not connected" };
83867
83867
  }
83868
83868
  const requestId = `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
83869
- return new Promise((resolve27) => {
83869
+ return new Promise((resolve28) => {
83870
83870
  const handler = (data) => {
83871
83871
  if (data.requestId === requestId) {
83872
83872
  clearTimeout(timeout);
83873
83873
  this.socket.off("fw:ack", handler);
83874
- resolve27(data);
83874
+ resolve28(data);
83875
83875
  }
83876
83876
  };
83877
83877
  const timeout = setTimeout(() => {
83878
83878
  this.socket.off("fw:ack", handler);
83879
- resolve27({ requestId, success: false, error: "Timeout" });
83879
+ resolve28({ requestId, success: false, error: "Timeout" });
83880
83880
  }, this.ackTimeout);
83881
83881
  this.socket.on("fw:ack", handler);
83882
83882
  this.socket.emit("integration:command", { requestId, action, params });
@@ -83893,17 +83893,17 @@ var EditorConnection = class {
83893
83893
  return { requestId: "", success: false, error: "Not connected" };
83894
83894
  }
83895
83895
  const requestId = `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
83896
- return new Promise((resolve27) => {
83896
+ return new Promise((resolve28) => {
83897
83897
  const handler = (data) => {
83898
83898
  if (data.requestId === requestId) {
83899
83899
  clearTimeout(timeout);
83900
83900
  this.socket.off("fw:ack", handler);
83901
- resolve27(data);
83901
+ resolve28(data);
83902
83902
  }
83903
83903
  };
83904
83904
  const timeout = setTimeout(() => {
83905
83905
  this.socket.off("fw:ack", handler);
83906
- resolve27({ requestId, success: false, error: "Timeout" });
83906
+ resolve28({ requestId, success: false, error: "Timeout" });
83907
83907
  }, this.ackTimeout);
83908
83908
  this.socket.on("fw:ack", handler);
83909
83909
  this.socket.emit("integration:batch", { requestId, commands });
@@ -83931,11 +83931,11 @@ function defaultRegistrationDeps() {
83931
83931
  return { stdout: "", exitCode: 1 };
83932
83932
  }
83933
83933
  },
83934
- prompt: (question) => new Promise((resolve27) => {
83934
+ prompt: (question) => new Promise((resolve28) => {
83935
83935
  const rl = readline8.createInterface({ input: process.stdin, output: process.stderr });
83936
83936
  rl.question(question, (answer) => {
83937
83937
  rl.close();
83938
- resolve27(answer.trim().toLowerCase());
83938
+ resolve28(answer.trim().toLowerCase());
83939
83939
  });
83940
83940
  }),
83941
83941
  log: (msg) => process.stderr.write(msg + "\n"),
@@ -84052,8 +84052,8 @@ var AgentChannel = class {
84052
84052
  */
84053
84053
  async request(agentRequest) {
84054
84054
  this._pauseResolve?.(agentRequest);
84055
- return new Promise((resolve27, reject2) => {
84056
- this._resolve = resolve27;
84055
+ return new Promise((resolve28, reject2) => {
84056
+ this._resolve = resolve28;
84057
84057
  this._reject = reject2;
84058
84058
  });
84059
84059
  }
@@ -84083,8 +84083,8 @@ var AgentChannel = class {
84083
84083
  this._pausePromise = this._createPausePromise();
84084
84084
  }
84085
84085
  _createPausePromise() {
84086
- return new Promise((resolve27) => {
84087
- this._pauseResolve = resolve27;
84086
+ return new Promise((resolve28) => {
84087
+ this._pauseResolve = resolve28;
84088
84088
  });
84089
84089
  }
84090
84090
  };
@@ -84636,8 +84636,8 @@ ${parseResult.errors.join("\n")}`);
84636
84636
  });
84637
84637
  const outputFile = filePath.replace(/\.ts$/, ".inngest.ts");
84638
84638
  if (args.write !== false) {
84639
- const fs37 = await import("fs");
84640
- fs37.writeFileSync(outputFile, code, "utf8");
84639
+ const fs38 = await import("fs");
84640
+ fs38.writeFileSync(outputFile, code, "utf8");
84641
84641
  }
84642
84642
  return makeToolResult({
84643
84643
  target: "inngest",
@@ -86067,8 +86067,8 @@ var OpenAPIGenerator = class {
86067
86067
  doc.paths["/health"] = this.generateHealthEndpoint();
86068
86068
  doc.paths["/workflows"] = this.generateListEndpoint();
86069
86069
  for (const endpoint of endpoints) {
86070
- const path38 = options.basePath ? `${options.basePath}${endpoint.path}` : endpoint.path;
86071
- doc.paths[path38] = this.generateWorkflowEndpoint(endpoint);
86070
+ const path39 = options.basePath ? `${options.basePath}${endpoint.path}` : endpoint.path;
86071
+ doc.paths[path39] = this.generateWorkflowEndpoint(endpoint);
86072
86072
  }
86073
86073
  return doc;
86074
86074
  }
@@ -86445,8 +86445,8 @@ var BaseExportTarget = class {
86445
86445
  * Get relative import path for the workflow
86446
86446
  */
86447
86447
  getWorkflowImport(workflowFile) {
86448
- const basename16 = path24.basename(workflowFile, path24.extname(workflowFile));
86449
- return `./${basename16}.js`;
86448
+ const basename17 = path24.basename(workflowFile, path24.extname(workflowFile));
86449
+ return `./${basename17}.js`;
86450
86450
  }
86451
86451
  /**
86452
86452
  * Generate OpenAPI spec for node types as HTTP endpoints
@@ -92093,20 +92093,20 @@ async function sendCommand(serverUrl, action, params) {
92093
92093
  transports: ["websocket", "polling"]
92094
92094
  });
92095
92095
  try {
92096
- await new Promise((resolve27, reject2) => {
92097
- socket.on("connect", () => resolve27());
92096
+ await new Promise((resolve28, reject2) => {
92097
+ socket.on("connect", () => resolve28());
92098
92098
  socket.on("connect_error", (err) => reject2(err));
92099
92099
  setTimeout(() => reject2(new Error("Connection timeout")), ACK_TIMEOUT);
92100
92100
  });
92101
92101
  const requestId = `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
92102
- const result = await new Promise((resolve27) => {
92102
+ const result = await new Promise((resolve28) => {
92103
92103
  const timeout = setTimeout(() => {
92104
- resolve27({ requestId, success: false, error: "Timeout" });
92104
+ resolve28({ requestId, success: false, error: "Timeout" });
92105
92105
  }, ACK_TIMEOUT);
92106
92106
  socket.on("fw:ack", (data) => {
92107
92107
  if (data.requestId === requestId) {
92108
92108
  clearTimeout(timeout);
92109
- resolve27(data);
92109
+ resolve28(data);
92110
92110
  }
92111
92111
  });
92112
92112
  socket.emit("integration:command", { requestId, action, params });
@@ -92136,20 +92136,20 @@ async function sendBatch(serverUrl, commands) {
92136
92136
  transports: ["websocket", "polling"]
92137
92137
  });
92138
92138
  try {
92139
- await new Promise((resolve27, reject2) => {
92140
- socket.on("connect", () => resolve27());
92139
+ await new Promise((resolve28, reject2) => {
92140
+ socket.on("connect", () => resolve28());
92141
92141
  socket.on("connect_error", (err) => reject2(err));
92142
92142
  setTimeout(() => reject2(new Error("Connection timeout")), ACK_TIMEOUT);
92143
92143
  });
92144
92144
  const requestId = `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
92145
- const result = await new Promise((resolve27) => {
92145
+ const result = await new Promise((resolve28) => {
92146
92146
  const timeout = setTimeout(() => {
92147
- resolve27({ requestId, success: false, error: "Timeout" });
92147
+ resolve28({ requestId, success: false, error: "Timeout" });
92148
92148
  }, ACK_TIMEOUT);
92149
92149
  socket.on("fw:ack", (data) => {
92150
92150
  if (data.requestId === requestId) {
92151
92151
  clearTimeout(timeout);
92152
- resolve27(data);
92152
+ resolve28(data);
92153
92153
  }
92154
92154
  });
92155
92155
  socket.emit("integration:batch", { requestId, commands });
@@ -92467,7 +92467,7 @@ async function validateMockConfig(mocks, filePath, workflowName) {
92467
92467
  }
92468
92468
  }
92469
92469
  function promptForInput(question) {
92470
- return new Promise((resolve27) => {
92470
+ return new Promise((resolve28) => {
92471
92471
  const rl = readline9.createInterface({
92472
92472
  input: process.stdin,
92473
92473
  output: process.stderr
@@ -92475,7 +92475,7 @@ function promptForInput(question) {
92475
92475
  });
92476
92476
  rl.question(question, (answer) => {
92477
92477
  rl.close();
92478
- resolve27(answer.trim());
92478
+ resolve28(answer.trim());
92479
92479
  });
92480
92480
  });
92481
92481
  }
@@ -92948,7 +92948,7 @@ async function serveCommand(dir, options) {
92948
92948
  process.exit(0);
92949
92949
  };
92950
92950
  process.on("SIGINT", () => shutdown("SIGINT"));
92951
- process.on("SIGTERM", () => shutdown("SIGTERM"));
92951
+ if (process.platform !== "win32") process.on("SIGTERM", () => shutdown("SIGTERM"));
92952
92952
  try {
92953
92953
  await server.start();
92954
92954
  } catch (error2) {
@@ -94604,7 +94604,7 @@ function getCommits(rangeArg) {
94604
94604
  return [];
94605
94605
  }
94606
94606
  const entries = [];
94607
- for (const line of logOutput.split("\n")) {
94607
+ for (const line of logOutput.split(/\r?\n/)) {
94608
94608
  if (!line.trim()) continue;
94609
94609
  const spaceIdx = line.indexOf(" ");
94610
94610
  const hash = line.slice(0, spaceIdx);
@@ -94614,7 +94614,7 @@ function getCommits(rangeArg) {
94614
94614
  const filesOutput = execSync5(`git diff-tree --no-commit-id --name-only -r ${hash}`, {
94615
94615
  encoding: "utf8"
94616
94616
  }).trim();
94617
- files = filesOutput ? filesOutput.split("\n") : [];
94617
+ files = filesOutput ? filesOutput.split(/\r?\n/) : [];
94618
94618
  } catch {
94619
94619
  files = [];
94620
94620
  }
@@ -94660,6 +94660,61 @@ async function changelogCommand(options = {}) {
94660
94660
  }
94661
94661
  }
94662
94662
 
94663
+ // src/cli/commands/strip.ts
94664
+ init_esm5();
94665
+ import * as fs36 from "fs";
94666
+ import * as path37 from "path";
94667
+ async function stripCommand(input, options = {}) {
94668
+ const { output, dryRun = false, verbose = false } = options;
94669
+ let pattern = input;
94670
+ try {
94671
+ if (fs36.existsSync(input) && fs36.statSync(input).isDirectory()) {
94672
+ pattern = path37.join(input, "**/*.ts");
94673
+ }
94674
+ } catch {
94675
+ }
94676
+ const allFiles = await glob(pattern, { absolute: true });
94677
+ const files = allFiles.filter((f) => {
94678
+ try {
94679
+ return fs36.statSync(f).isFile();
94680
+ } catch {
94681
+ return false;
94682
+ }
94683
+ });
94684
+ if (files.length === 0) {
94685
+ logger.error(`No files found matching pattern: ${input}`);
94686
+ process.exit(1);
94687
+ }
94688
+ let stripped = 0;
94689
+ let skipped = 0;
94690
+ for (const filePath of files) {
94691
+ const content = fs36.readFileSync(filePath, "utf-8");
94692
+ if (!hasInPlaceMarkers(content)) {
94693
+ skipped++;
94694
+ if (verbose) {
94695
+ logger.info(`Skipped (no markers): ${path37.relative(process.cwd(), filePath)}`);
94696
+ }
94697
+ continue;
94698
+ }
94699
+ const result = stripGeneratedSections(content);
94700
+ if (dryRun) {
94701
+ logger.info(`Would strip: ${path37.relative(process.cwd(), filePath)}`);
94702
+ stripped++;
94703
+ continue;
94704
+ }
94705
+ const outPath = output ? path37.join(path37.resolve(output), path37.basename(filePath)) : filePath;
94706
+ if (output) {
94707
+ fs36.mkdirSync(path37.dirname(outPath), { recursive: true });
94708
+ }
94709
+ fs36.writeFileSync(outPath, result);
94710
+ stripped++;
94711
+ if (verbose) {
94712
+ logger.success(`Stripped: ${path37.relative(process.cwd(), outPath)}`);
94713
+ }
94714
+ }
94715
+ logger.success(`${stripped} file${stripped !== 1 ? "s" : ""} stripped, ${skipped} skipped`);
94716
+ }
94717
+
94663
94718
  // src/cli/commands/docs.ts
94664
94719
  async function docsListCommand(options) {
94665
94720
  const topics = listTopics();
@@ -94734,8 +94789,8 @@ async function docsSearchCommand(query, options) {
94734
94789
  }
94735
94790
 
94736
94791
  // src/cli/commands/market.ts
94737
- import * as fs36 from "fs";
94738
- import * as path37 from "path";
94792
+ import * as fs37 from "fs";
94793
+ import * as path38 from "path";
94739
94794
  import { execSync as execSync6 } from "child_process";
94740
94795
  async function marketInitCommand(name, options = {}) {
94741
94796
  if (!name.startsWith("flowweaver-pack-")) {
@@ -94743,11 +94798,11 @@ async function marketInitCommand(name, options = {}) {
94743
94798
  logger.warn(`Name should follow "flowweaver-pack-*" convention, using "${suggested}"`);
94744
94799
  name = suggested;
94745
94800
  }
94746
- const targetDir = path37.resolve(name);
94747
- if (fs36.existsSync(targetDir)) {
94748
- const stat = fs36.statSync(targetDir);
94801
+ const targetDir = path38.resolve(name);
94802
+ if (fs37.existsSync(targetDir)) {
94803
+ const stat = fs37.statSync(targetDir);
94749
94804
  if (stat.isDirectory()) {
94750
- const contents = fs36.readdirSync(targetDir);
94805
+ const contents = fs37.readdirSync(targetDir);
94751
94806
  if (contents.length > 0) {
94752
94807
  logger.error(`Directory "${name}" already exists and is not empty`);
94753
94808
  process.exit(1);
@@ -94762,13 +94817,13 @@ async function marketInitCommand(name, options = {}) {
94762
94817
  logger.newline();
94763
94818
  const dirs = [
94764
94819
  targetDir,
94765
- path37.join(targetDir, "src"),
94766
- path37.join(targetDir, "src", "node-types"),
94767
- path37.join(targetDir, "src", "workflows"),
94768
- path37.join(targetDir, "src", "patterns")
94820
+ path38.join(targetDir, "src"),
94821
+ path38.join(targetDir, "src", "node-types"),
94822
+ path38.join(targetDir, "src", "workflows"),
94823
+ path38.join(targetDir, "src", "patterns")
94769
94824
  ];
94770
94825
  for (const dir of dirs) {
94771
- fs36.mkdirSync(dir, { recursive: true });
94826
+ fs37.mkdirSync(dir, { recursive: true });
94772
94827
  }
94773
94828
  const shortName = name.replace(/^flowweaver-pack-/, "");
94774
94829
  const pkg = {
@@ -94799,8 +94854,8 @@ async function marketInitCommand(name, options = {}) {
94799
94854
  },
94800
94855
  files: ["dist", "flowweaver.manifest.json", "README.md", "LICENSE"]
94801
94856
  };
94802
- fs36.writeFileSync(
94803
- path37.join(targetDir, "package.json"),
94857
+ fs37.writeFileSync(
94858
+ path38.join(targetDir, "package.json"),
94804
94859
  JSON.stringify(pkg, null, 2) + "\n"
94805
94860
  );
94806
94861
  const tsconfig = {
@@ -94818,8 +94873,8 @@ async function marketInitCommand(name, options = {}) {
94818
94873
  include: ["src"],
94819
94874
  exclude: ["node_modules", "dist"]
94820
94875
  };
94821
- fs36.writeFileSync(
94822
- path37.join(targetDir, "tsconfig.json"),
94876
+ fs37.writeFileSync(
94877
+ path38.join(targetDir, "tsconfig.json"),
94823
94878
  JSON.stringify(tsconfig, null, 2) + "\n"
94824
94879
  );
94825
94880
  const sampleNodeType = `/**
@@ -94837,21 +94892,21 @@ export function sample(execute: () => void, data: string): { result: string } {
94837
94892
  return { result: data.toUpperCase() };
94838
94893
  }
94839
94894
  `;
94840
- fs36.writeFileSync(path37.join(targetDir, "src", "node-types", "sample.ts"), sampleNodeType);
94841
- fs36.writeFileSync(
94842
- path37.join(targetDir, "src", "node-types", "index.ts"),
94895
+ fs37.writeFileSync(path38.join(targetDir, "src", "node-types", "sample.ts"), sampleNodeType);
94896
+ fs37.writeFileSync(
94897
+ path38.join(targetDir, "src", "node-types", "index.ts"),
94843
94898
  "export { sample } from './sample.js';\n"
94844
94899
  );
94845
- fs36.writeFileSync(
94846
- path37.join(targetDir, "src", "workflows", "index.ts"),
94900
+ fs37.writeFileSync(
94901
+ path38.join(targetDir, "src", "workflows", "index.ts"),
94847
94902
  "// Export workflows here\n"
94848
94903
  );
94849
- fs36.writeFileSync(
94850
- path37.join(targetDir, "src", "patterns", "index.ts"),
94904
+ fs37.writeFileSync(
94905
+ path38.join(targetDir, "src", "patterns", "index.ts"),
94851
94906
  "// Export patterns here\n"
94852
94907
  );
94853
- fs36.writeFileSync(
94854
- path37.join(targetDir, "src", "index.ts"),
94908
+ fs37.writeFileSync(
94909
+ path38.join(targetDir, "src", "index.ts"),
94855
94910
  [
94856
94911
  "export * from './node-types/index.js';",
94857
94912
  "export * from './workflows/index.js';",
@@ -94884,9 +94939,9 @@ npm run pack # Generate flowweaver.manifest.json
94884
94939
  npm publish # Publish to npm
94885
94940
  \`\`\`
94886
94941
  `;
94887
- fs36.writeFileSync(path37.join(targetDir, "README.md"), readme);
94888
- fs36.writeFileSync(
94889
- path37.join(targetDir, ".gitignore"),
94942
+ fs37.writeFileSync(path38.join(targetDir, "README.md"), readme);
94943
+ fs37.writeFileSync(
94944
+ path38.join(targetDir, ".gitignore"),
94890
94945
  ["node_modules", "dist", "*.tgz", ""].join("\n")
94891
94946
  );
94892
94947
  logger.success("Created package.json");
@@ -94906,7 +94961,7 @@ npm publish # Publish to npm
94906
94961
  logger.newline();
94907
94962
  }
94908
94963
  async function marketPackCommand(directory, options = {}) {
94909
- const dir = path37.resolve(directory ?? ".");
94964
+ const dir = path38.resolve(directory ?? ".");
94910
94965
  const { json: json2 = false, verbose = false } = options;
94911
94966
  if (!json2) {
94912
94967
  logger.section("Packing Marketplace Package");
@@ -94945,21 +95000,21 @@ async function marketPackCommand(directory, options = {}) {
94945
95000
  }
94946
95001
  const outPath = writeManifest(dir, manifest);
94947
95002
  logger.newline();
94948
- logger.success(`Manifest written to ${path37.relative(dir, outPath)}`);
95003
+ logger.success(`Manifest written to ${path38.relative(dir, outPath)}`);
94949
95004
  if (warnings.length > 0) {
94950
95005
  logger.warn(`${warnings.length} warning(s) \u2014 consider fixing before publishing`);
94951
95006
  }
94952
95007
  logger.newline();
94953
95008
  }
94954
95009
  async function marketPublishCommand(directory, options = {}) {
94955
- const dir = path37.resolve(directory ?? ".");
95010
+ const dir = path38.resolve(directory ?? ".");
94956
95011
  const { dryRun = false, tag } = options;
94957
95012
  logger.section("Publishing Marketplace Package");
94958
95013
  await marketPackCommand(dir, { json: false });
94959
- if (!fs36.existsSync(path37.join(dir, "LICENSE"))) {
95014
+ if (!fs37.existsSync(path38.join(dir, "LICENSE"))) {
94960
95015
  logger.warn("LICENSE file not found \u2014 consider adding one");
94961
95016
  }
94962
- const pkg = JSON.parse(fs36.readFileSync(path37.join(dir, "package.json"), "utf-8"));
95017
+ const pkg = JSON.parse(fs37.readFileSync(path38.join(dir, "package.json"), "utf-8"));
94963
95018
  logger.info(`Publishing ${pkg.name}@${pkg.version}`);
94964
95019
  const npmArgs = ["publish"];
94965
95020
  if (dryRun) npmArgs.push("--dry-run");
@@ -94994,7 +95049,7 @@ async function marketInstallCommand(packageSpec, options = {}) {
94994
95049
  process.exit(1);
94995
95050
  }
94996
95051
  const packageName = resolvePackageName2(packageSpec);
94997
- const manifest = readManifest(path37.join(process.cwd(), "node_modules", packageName));
95052
+ const manifest = readManifest(path38.join(process.cwd(), "node_modules", packageName));
94998
95053
  if (json2) {
94999
95054
  console.log(JSON.stringify({
95000
95055
  success: true,
@@ -95078,7 +95133,7 @@ async function marketListCommand(options = {}) {
95078
95133
  }
95079
95134
  function resolvePackageName2(spec) {
95080
95135
  if (spec.endsWith(".tgz") || spec.endsWith(".tar.gz")) {
95081
- const base = path37.basename(spec, spec.endsWith(".tar.gz") ? ".tar.gz" : ".tgz");
95136
+ const base = path38.basename(spec, spec.endsWith(".tar.gz") ? ".tar.gz" : ".tgz");
95082
95137
  const match2 = base.match(/^(.+)-\d+\.\d+\.\d+/);
95083
95138
  return match2 ? match2[1] : base;
95084
95139
  }
@@ -95127,7 +95182,7 @@ function displayInstalledPackage(pkg) {
95127
95182
  }
95128
95183
 
95129
95184
  // src/cli/index.ts
95130
- var version2 = true ? "0.8.1" : "0.0.0-dev";
95185
+ var version2 = true ? "0.8.2" : "0.0.0-dev";
95131
95186
  var program2 = new Command();
95132
95187
  program2.name("flow-weaver").description("Flow Weaver Annotations - Compile and validate workflow files").version(version2, "-v, --version", "Output the current version");
95133
95188
  program2.configureOutput({
@@ -95147,6 +95202,14 @@ program2.command("compile <input>").description("Compile workflow files to TypeS
95147
95202
  process.exit(1);
95148
95203
  }
95149
95204
  });
95205
+ program2.command("strip <input>").description("Remove generated code from compiled workflow files").option("-o, --output <path>", "Output directory (default: in-place)").option("--dry-run", "Preview without writing", false).option("--verbose", "Verbose output", false).action(async (input, options) => {
95206
+ try {
95207
+ await stripCommand(input, options);
95208
+ } catch (error2) {
95209
+ logger.error(`Command failed: ${getErrorMessage(error2)}`);
95210
+ process.exit(1);
95211
+ }
95212
+ });
95150
95213
  program2.command("describe <input>").description("Output workflow structure in LLM-friendly formats (JSON, text, mermaid)").option("-f, --format <format>", "Output format: json (default), text, mermaid", "json").option("-n, --node <id>", "Focus on a specific node").option("--compile", "Also update runtime markers in the source file").option("-w, --workflow-name <name>", "Specific workflow name to describe").action(async (input, options) => {
95151
95214
  try {
95152
95215
  await describeCommand(input, options);