@base44-preview/cli 0.0.44-pr.381.3470954 → 0.0.44-pr.382.bab01f6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli/index.js CHANGED
@@ -16459,7 +16459,7 @@ var require_lodash = __commonJS((exports, module) => {
16459
16459
  }
16460
16460
  return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, undefined2, comparator) : [];
16461
16461
  });
16462
- function join10(array2, separator) {
16462
+ function join11(array2, separator) {
16463
16463
  return array2 == null ? "" : nativeJoin.call(array2, separator);
16464
16464
  }
16465
16465
  function last(array2) {
@@ -16481,7 +16481,7 @@ var require_lodash = __commonJS((exports, module) => {
16481
16481
  function nth(array2, n2) {
16482
16482
  return array2 && array2.length ? baseNth(array2, toInteger(n2)) : undefined2;
16483
16483
  }
16484
- var pull2 = baseRest(pullAll);
16484
+ var pull3 = baseRest(pullAll);
16485
16485
  function pullAll(array2, values2) {
16486
16486
  return array2 && array2.length && values2 && values2.length ? basePullAll(array2, values2) : array2;
16487
16487
  }
@@ -18246,7 +18246,7 @@ __p += '`;
18246
18246
  lodash.pickBy = pickBy;
18247
18247
  lodash.property = property;
18248
18248
  lodash.propertyOf = propertyOf;
18249
- lodash.pull = pull2;
18249
+ lodash.pull = pull3;
18250
18250
  lodash.pullAll = pullAll;
18251
18251
  lodash.pullAllBy = pullAllBy;
18252
18252
  lodash.pullAllWith = pullAllWith;
@@ -18391,7 +18391,7 @@ __p += '`;
18391
18391
  lodash.isUndefined = isUndefined;
18392
18392
  lodash.isWeakMap = isWeakMap;
18393
18393
  lodash.isWeakSet = isWeakSet;
18394
- lodash.join = join10;
18394
+ lodash.join = join11;
18395
18395
  lodash.kebabCase = kebabCase;
18396
18396
  lodash.last = last;
18397
18397
  lodash.lastIndexOf = lastIndexOf;
@@ -27503,7 +27503,7 @@ function cleanDoc(doc2) {
27503
27503
  return mapDoc(doc2, (currentDoc) => cleanDocFn(currentDoc));
27504
27504
  }
27505
27505
  function replaceEndOfLine(doc2, replacement = literalline) {
27506
- return mapDoc(doc2, (currentDoc) => typeof currentDoc === "string" ? join13(replacement, currentDoc.split(`
27506
+ return mapDoc(doc2, (currentDoc) => typeof currentDoc === "string" ? join15(replacement, currentDoc.split(`
27507
27507
  `)) : currentDoc);
27508
27508
  }
27509
27509
  function canBreakFn(doc2) {
@@ -27583,7 +27583,7 @@ function indentIfBreak(contents, options) {
27583
27583
  negate: options.negate
27584
27584
  };
27585
27585
  }
27586
- function join13(separator, docs) {
27586
+ function join15(separator, docs) {
27587
27587
  assertDoc(separator);
27588
27588
  assertDocArray(docs);
27589
27589
  const parts = [];
@@ -28294,7 +28294,7 @@ var init_doc = __esm(() => {
28294
28294
  MODE_FLAT = Symbol("MODE_FLAT");
28295
28295
  DOC_FILL_PRINTED_LENGTH = Symbol("DOC_FILL_PRINTED_LENGTH");
28296
28296
  builders = {
28297
- join: join13,
28297
+ join: join15,
28298
28298
  line,
28299
28299
  softline,
28300
28300
  hardline,
@@ -133208,7 +133208,7 @@ Expected it to be ${EXPECTED_TYPE_VALUES}.`;
133208
133208
  return mapDoc2(doc2, (currentDoc) => cleanDocFn2(currentDoc));
133209
133209
  }
133210
133210
  function replaceEndOfLine2(doc2, replacement = literalline2) {
133211
- return mapDoc2(doc2, (currentDoc) => typeof currentDoc === "string" ? join15(replacement, currentDoc.split(`
133211
+ return mapDoc2(doc2, (currentDoc) => typeof currentDoc === "string" ? join17(replacement, currentDoc.split(`
133212
133212
  `)) : currentDoc);
133213
133213
  }
133214
133214
  function canBreakFn2(doc2) {
@@ -133294,7 +133294,7 @@ Expected it to be ${EXPECTED_TYPE_VALUES}.`;
133294
133294
  negate: options8.negate
133295
133295
  };
133296
133296
  }
133297
- function join15(separator, docs) {
133297
+ function join17(separator, docs) {
133298
133298
  assertDoc2(separator);
133299
133299
  assertDocArray2(docs);
133300
133300
  const parts = [];
@@ -133959,7 +133959,7 @@ Expected it to be ${EXPECTED_TYPE_VALUES}.`;
133959
133959
  }
133960
133960
  }
133961
133961
  var builders2 = {
133962
- join: join15,
133962
+ join: join17,
133963
133963
  line: line3,
133964
133964
  softline: softline2,
133965
133965
  hardline: hardline4,
@@ -160399,10 +160399,10 @@ var require_view = __commonJS((exports, module) => {
160399
160399
  var debug = require_src4()("express:view");
160400
160400
  var path18 = __require("node:path");
160401
160401
  var fs28 = __require("node:fs");
160402
- var dirname11 = path18.dirname;
160402
+ var dirname12 = path18.dirname;
160403
160403
  var basename4 = path18.basename;
160404
160404
  var extname2 = path18.extname;
160405
- var join16 = path18.join;
160405
+ var join18 = path18.join;
160406
160406
  var resolve6 = path18.resolve;
160407
160407
  module.exports = View;
160408
160408
  function View(name2, options8) {
@@ -160438,7 +160438,7 @@ var require_view = __commonJS((exports, module) => {
160438
160438
  for (var i5 = 0;i5 < roots.length && !path19; i5++) {
160439
160439
  var root2 = roots[i5];
160440
160440
  var loc = resolve6(root2, name2);
160441
- var dir = dirname11(loc);
160441
+ var dir = dirname12(loc);
160442
160442
  var file2 = basename4(loc);
160443
160443
  path19 = this.resolve(dir, file2);
160444
160444
  }
@@ -160464,12 +160464,12 @@ var require_view = __commonJS((exports, module) => {
160464
160464
  };
160465
160465
  View.prototype.resolve = function resolve7(dir, file2) {
160466
160466
  var ext = this.ext;
160467
- var path19 = join16(dir, file2);
160467
+ var path19 = join18(dir, file2);
160468
160468
  var stat2 = tryStat(path19);
160469
160469
  if (stat2 && stat2.isFile()) {
160470
160470
  return path19;
160471
160471
  }
160472
- path19 = join16(dir, basename4(file2, ext), "index" + ext);
160472
+ path19 = join18(dir, basename4(file2, ext), "index" + ext);
160473
160473
  stat2 = tryStat(path19);
160474
160474
  if (stat2 && stat2.isFile()) {
160475
160475
  return path19;
@@ -164164,7 +164164,7 @@ var require_send = __commonJS((exports, module) => {
164164
164164
  var Stream2 = __require("stream");
164165
164165
  var util2 = __require("util");
164166
164166
  var extname2 = path18.extname;
164167
- var join16 = path18.join;
164167
+ var join18 = path18.join;
164168
164168
  var normalize = path18.normalize;
164169
164169
  var resolve6 = path18.resolve;
164170
164170
  var sep = path18.sep;
@@ -164336,7 +164336,7 @@ var require_send = __commonJS((exports, module) => {
164336
164336
  return res;
164337
164337
  }
164338
164338
  parts = path19.split(sep);
164339
- path19 = normalize(join16(root2, path19));
164339
+ path19 = normalize(join18(root2, path19));
164340
164340
  } else {
164341
164341
  if (UP_PATH_REGEXP.test(path19)) {
164342
164342
  debug('malicious path "%s"', path19);
@@ -164476,7 +164476,7 @@ var require_send = __commonJS((exports, module) => {
164476
164476
  return self2.onStatError(err);
164477
164477
  return self2.error(404);
164478
164478
  }
164479
- var p4 = join16(path19, self2._index[i5]);
164479
+ var p4 = join18(path19, self2._index[i5]);
164480
164480
  debug('stat "%s"', p4);
164481
164481
  fs28.stat(p4, function(err2, stat2) {
164482
164482
  if (err2)
@@ -211071,7 +211071,7 @@ var require_buffer_list = __commonJS((exports, module) => {
211071
211071
  }
211072
211072
  }, {
211073
211073
  key: "join",
211074
- value: function join16(s5) {
211074
+ value: function join18(s5) {
211075
211075
  if (this.length === 0)
211076
211076
  return "";
211077
211077
  var p4 = this.head;
@@ -214782,7 +214782,7 @@ var require_dist5 = __commonJS((exports, module) => {
214782
214782
  });
214783
214783
 
214784
214784
  // src/cli/index.ts
214785
- import { dirname as dirname15, join as join19 } from "node:path";
214785
+ import { dirname as dirname16, join as join21 } from "node:path";
214786
214786
  import { fileURLToPath as fileURLToPath6 } from "node:url";
214787
214787
 
214788
214788
  // ../../node_modules/commander/esm.mjs
@@ -214802,7 +214802,7 @@ var {
214802
214802
  } = import__.default;
214803
214803
 
214804
214804
  // src/cli/commands/agents/pull.ts
214805
- import { dirname as dirname7, join as join10 } from "node:path";
214805
+ import { dirname as dirname7, join as join11 } from "node:path";
214806
214806
 
214807
214807
  // ../../node_modules/@clack/core/dist/index.mjs
214808
214808
  var import_picocolors = __toESM(require_picocolors(), 1);
@@ -237317,7 +237317,7 @@ var generateGlobTasks = normalizeArguments(generateTasks);
237317
237317
  var generateGlobTasksSync = normalizeArgumentsSync(generateTasksSync);
237318
237318
 
237319
237319
  // src/core/project/config.ts
237320
- import { dirname as dirname5, join as join6 } from "node:path";
237320
+ import { dirname as dirname5, join as join7 } from "node:path";
237321
237321
 
237322
237322
  // src/core/resources/agent/schema.ts
237323
237323
  var EntityOperationSchema = exports_external.enum(["create", "update", "delete", "read"]);
@@ -238463,6 +238463,66 @@ async function pushFunctions(functions) {
238463
238463
  const functionsWithCode = await Promise.all(functions.map(loadFunctionCode));
238464
238464
  return deployFunctions(functionsWithCode);
238465
238465
  }
238466
+ // src/core/resources/function/pull.ts
238467
+ import { join as join6 } from "node:path";
238468
+ import { isDeepStrictEqual as isDeepStrictEqual3 } from "node:util";
238469
+ async function writeFunctions(functionsDir, functions) {
238470
+ const written = [];
238471
+ const skipped = [];
238472
+ for (const fn of functions) {
238473
+ const functionDir = join6(functionsDir, fn.name);
238474
+ const configPath = join6(functionDir, "function.jsonc");
238475
+ if (await isFunctionUnchanged(functionDir, fn)) {
238476
+ skipped.push(fn.name);
238477
+ continue;
238478
+ }
238479
+ const config5 = {
238480
+ name: fn.name,
238481
+ entry: fn.entry
238482
+ };
238483
+ if (fn.automations.length > 0) {
238484
+ config5.automations = fn.automations;
238485
+ }
238486
+ await writeJsonFile(configPath, config5);
238487
+ for (const file2 of fn.files) {
238488
+ await writeFile(join6(functionDir, file2.path), file2.content);
238489
+ }
238490
+ written.push(fn.name);
238491
+ }
238492
+ return { written, skipped };
238493
+ }
238494
+ async function isFunctionUnchanged(functionDir, fn) {
238495
+ if (!await pathExists(functionDir)) {
238496
+ return false;
238497
+ }
238498
+ const configPath = join6(functionDir, "function.jsonc");
238499
+ try {
238500
+ const localConfig = await readJsonFile(configPath);
238501
+ if (localConfig.entry !== fn.entry) {
238502
+ return false;
238503
+ }
238504
+ if (!isDeepStrictEqual3(localConfig.automations ?? [], fn.automations)) {
238505
+ return false;
238506
+ }
238507
+ } catch {
238508
+ return false;
238509
+ }
238510
+ for (const file2 of fn.files) {
238511
+ const filePath = join6(functionDir, file2.path);
238512
+ if (!await pathExists(filePath)) {
238513
+ return false;
238514
+ }
238515
+ try {
238516
+ const localContent = await readTextFile(filePath);
238517
+ if (localContent !== file2.content) {
238518
+ return false;
238519
+ }
238520
+ } catch {
238521
+ return false;
238522
+ }
238523
+ }
238524
+ return true;
238525
+ }
238466
238526
  // src/core/resources/function/resource.ts
238467
238527
  var functionResource = {
238468
238528
  readAll: readAllFunctions,
@@ -238507,10 +238567,10 @@ async function readProjectConfig(projectRoot) {
238507
238567
  const project = result.data;
238508
238568
  const configDir = dirname5(configPath);
238509
238569
  const [entities, functions, agents, connectors] = await Promise.all([
238510
- entityResource.readAll(join6(configDir, project.entitiesDir)),
238511
- functionResource.readAll(join6(configDir, project.functionsDir)),
238512
- agentResource.readAll(join6(configDir, project.agentsDir)),
238513
- connectorResource.readAll(join6(configDir, project.connectorsDir))
238570
+ entityResource.readAll(join7(configDir, project.entitiesDir)),
238571
+ functionResource.readAll(join7(configDir, project.functionsDir)),
238572
+ agentResource.readAll(join7(configDir, project.agentsDir)),
238573
+ connectorResource.readAll(join7(configDir, project.connectorsDir))
238514
238574
  ]);
238515
238575
  return {
238516
238576
  project: { ...project, root, configPath },
@@ -238607,12 +238667,12 @@ async function readAppConfig(projectRoot) {
238607
238667
  // src/core/project/template.ts
238608
238668
  var import_ejs = __toESM(require_ejs(), 1);
238609
238669
  var import_front_matter = __toESM(require_front_matter(), 1);
238610
- import { dirname as dirname6, join as join8 } from "node:path";
238670
+ import { dirname as dirname6, join as join9 } from "node:path";
238611
238671
 
238612
238672
  // src/core/assets.ts
238613
238673
  import { cpSync, existsSync } from "node:fs";
238614
238674
  import { homedir as homedir2 } from "node:os";
238615
- import { join as join7 } from "node:path";
238675
+ import { join as join8 } from "node:path";
238616
238676
  // package.json
238617
238677
  var package_default = {
238618
238678
  name: "base44",
@@ -238705,15 +238765,15 @@ var package_default = {
238705
238765
  };
238706
238766
 
238707
238767
  // src/core/assets.ts
238708
- var ASSETS_DIR = join7(homedir2(), ".base44", "assets", package_default.version);
238768
+ var ASSETS_DIR = join8(homedir2(), ".base44", "assets", package_default.version);
238709
238769
  function getTemplatesDir() {
238710
- return join7(ASSETS_DIR, "templates");
238770
+ return join8(ASSETS_DIR, "templates");
238711
238771
  }
238712
238772
  function getTemplatesIndexPath() {
238713
- return join7(ASSETS_DIR, "templates", "templates.json");
238773
+ return join8(ASSETS_DIR, "templates", "templates.json");
238714
238774
  }
238715
238775
  function getDenoWrapperPath() {
238716
- return join7(ASSETS_DIR, "deno-runtime", "main.js");
238776
+ return join8(ASSETS_DIR, "deno-runtime", "main.js");
238717
238777
  }
238718
238778
  function ensureNpmAssets(sourceDir) {
238719
238779
  if (existsSync(ASSETS_DIR))
@@ -238734,23 +238794,23 @@ async function listTemplates() {
238734
238794
  return result.data.templates;
238735
238795
  }
238736
238796
  async function renderTemplate(template, destPath, data) {
238737
- const templateDir = join8(getTemplatesDir(), template.path);
238797
+ const templateDir = join9(getTemplatesDir(), template.path);
238738
238798
  const files = await globby("**/*", {
238739
238799
  cwd: templateDir,
238740
238800
  dot: true,
238741
238801
  onlyFiles: true
238742
238802
  });
238743
238803
  for (const file2 of files) {
238744
- const srcPath = join8(templateDir, file2);
238804
+ const srcPath = join9(templateDir, file2);
238745
238805
  try {
238746
238806
  if (file2.endsWith(".ejs")) {
238747
238807
  const rendered = await import_ejs.default.renderFile(srcPath, data);
238748
238808
  const { attributes, body } = import_front_matter.default(rendered);
238749
- const destFile = attributes.outputFileName ? join8(dirname6(file2), attributes.outputFileName) : file2.replace(/\.ejs$/, "");
238750
- const destFilePath = join8(destPath, destFile);
238809
+ const destFile = attributes.outputFileName ? join9(dirname6(file2), attributes.outputFileName) : file2.replace(/\.ejs$/, "");
238810
+ const destFilePath = join9(destPath, destFile);
238751
238811
  await writeFile(destFilePath, body);
238752
238812
  } else {
238753
- const destFilePath = join8(destPath, file2);
238813
+ const destFilePath = join9(destPath, file2);
238754
238814
  await copyFile(srcPath, destFilePath);
238755
238815
  }
238756
238816
  } catch (error48) {
@@ -238849,7 +238909,7 @@ async function getSiteFilePaths(outputDir) {
238849
238909
  // src/core/site/deploy.ts
238850
238910
  import { randomUUID } from "node:crypto";
238851
238911
  import { tmpdir } from "node:os";
238852
- import { join as join9 } from "node:path";
238912
+ import { join as join10 } from "node:path";
238853
238913
  async function deploySite(siteOutputDir) {
238854
238914
  if (!await pathExists(siteOutputDir)) {
238855
238915
  throw new InvalidInputError(`Output directory does not exist: ${siteOutputDir}. Make sure to build your project first.`, {
@@ -238866,7 +238926,7 @@ async function deploySite(siteOutputDir) {
238866
238926
  ]
238867
238927
  });
238868
238928
  }
238869
- const archivePath = join9(tmpdir(), `base44-site-${randomUUID()}.tar.gz`);
238929
+ const archivePath = join10(tmpdir(), `base44-site-${randomUUID()}.tar.gz`);
238870
238930
  try {
238871
238931
  await createArchive(siteOutputDir, archivePath);
238872
238932
  return await uploadSite(archivePath);
@@ -246651,7 +246711,7 @@ function formatYaml(data, options = {}) {
246651
246711
  async function pullAgentsAction() {
246652
246712
  const { project: project2 } = await readProjectConfig();
246653
246713
  const configDir = dirname7(project2.configPath);
246654
- const agentsDir = join10(configDir, project2.agentsDir);
246714
+ const agentsDir = join11(configDir, project2.agentsDir);
246655
246715
  const remoteAgents = await runTask("Fetching agents from Base44", async () => {
246656
246716
  return await fetchAgents();
246657
246717
  }, {
@@ -246773,11 +246833,11 @@ function getConnectorsListAvailableCommand(context) {
246773
246833
  }
246774
246834
 
246775
246835
  // src/cli/commands/connectors/pull.ts
246776
- import { dirname as dirname8, join as join11 } from "node:path";
246836
+ import { dirname as dirname8, join as join12 } from "node:path";
246777
246837
  async function pullConnectorsAction() {
246778
246838
  const { project: project2 } = await readProjectConfig();
246779
246839
  const configDir = dirname8(project2.configPath);
246780
- const connectorsDir = join11(configDir, project2.connectorsDir);
246840
+ const connectorsDir = join12(configDir, project2.connectorsDir);
246781
246841
  const remoteConnectors = await runTask("Fetching connectors from Base44", async () => {
246782
246842
  return await pullAllConnectors();
246783
246843
  }, {
@@ -247758,13 +247818,57 @@ function getListCommand(context) {
247758
247818
  });
247759
247819
  }
247760
247820
 
247821
+ // src/cli/commands/functions/pull.ts
247822
+ import { dirname as dirname9, join as join13 } from "node:path";
247823
+ async function pullFunctionsAction(name2) {
247824
+ const { project: project2 } = await readProjectConfig();
247825
+ const configDir = dirname9(project2.configPath);
247826
+ const functionsDir = join13(configDir, project2.functionsDir);
247827
+ const remoteFunctions = await runTask("Fetching functions from Base44", async () => {
247828
+ const { functions } = await listDeployedFunctions();
247829
+ return functions;
247830
+ }, {
247831
+ successMessage: "Functions fetched successfully",
247832
+ errorMessage: "Failed to fetch functions"
247833
+ });
247834
+ const toPull = name2 ? remoteFunctions.filter((f) => f.name === name2) : remoteFunctions;
247835
+ if (name2 && toPull.length === 0) {
247836
+ return {
247837
+ outroMessage: `Function "${name2}" not found on remote`
247838
+ };
247839
+ }
247840
+ if (toPull.length === 0) {
247841
+ return { outroMessage: "No functions found on remote" };
247842
+ }
247843
+ const { written, skipped } = await runTask("Writing function files", async () => {
247844
+ return await writeFunctions(functionsDir, toPull);
247845
+ }, {
247846
+ successMessage: "Function files written successfully",
247847
+ errorMessage: "Failed to write function files"
247848
+ });
247849
+ for (const name3 of written) {
247850
+ R2.success(`${name3.padEnd(25)} written`);
247851
+ }
247852
+ for (const name3 of skipped) {
247853
+ R2.info(`${name3.padEnd(25)} unchanged`);
247854
+ }
247855
+ return {
247856
+ outroMessage: `Pulled ${toPull.length} function${toPull.length !== 1 ? "s" : ""} to ${functionsDir}`
247857
+ };
247858
+ }
247859
+ function getPullCommand(context) {
247860
+ return new Command("pull").description("Pull deployed functions from Base44").argument("[name]", "Pull a single function by name").action(async (name2) => {
247861
+ await runCommand(() => pullFunctionsAction(name2), { requireAuth: true }, context);
247862
+ });
247863
+ }
247864
+
247761
247865
  // src/cli/commands/functions/index.ts
247762
247866
  function getFunctionsCommand(context) {
247763
- return new Command("functions").description("Manage backend functions").addCommand(getDeployCommand(context)).addCommand(getDeleteCommand(context)).addCommand(getListCommand(context));
247867
+ return new Command("functions").description("Manage backend functions").addCommand(getDeployCommand(context)).addCommand(getDeleteCommand(context)).addCommand(getListCommand(context)).addCommand(getPullCommand(context));
247764
247868
  }
247765
247869
 
247766
247870
  // src/cli/commands/project/create.ts
247767
- import { basename as basename3, join as join12, resolve as resolve2 } from "node:path";
247871
+ import { basename as basename3, join as join14, resolve as resolve2 } from "node:path";
247768
247872
  var import_kebabCase = __toESM(require_kebabCase(), 1);
247769
247873
  var DEFAULT_TEMPLATE_ID = "backend-only";
247770
247874
  async function getTemplateById(templateId) {
@@ -247901,7 +248005,7 @@ async function executeCreate({
247901
248005
  updateMessage("Building project...");
247902
248006
  await execa({ cwd: resolvedPath, shell: true })`${buildCommand}`;
247903
248007
  updateMessage("Deploying site...");
247904
- return await deploySite(join12(resolvedPath, outputDirectory));
248008
+ return await deploySite(join14(resolvedPath, outputDirectory));
247905
248009
  }, {
247906
248010
  successMessage: theme.colors.base44Orange("Site deployed successfully"),
247907
248011
  errorMessage: "Failed to deploy site"
@@ -248551,10 +248655,10 @@ function toPascalCase(name2) {
248551
248655
  return name2.split(/[-_\s]+/).map((w8) => w8.charAt(0).toUpperCase() + w8.slice(1)).join("");
248552
248656
  }
248553
248657
  // src/core/types/update-project.ts
248554
- import { join as join15 } from "node:path";
248658
+ import { join as join17 } from "node:path";
248555
248659
  var TYPES_INCLUDE_PATH = `${PROJECT_SUBDIR}/${TYPES_OUTPUT_SUBDIR}/*.d.ts`;
248556
248660
  async function updateProjectConfig(projectRoot) {
248557
- const tsconfigPath = join15(projectRoot, "tsconfig.json");
248661
+ const tsconfigPath = join17(projectRoot, "tsconfig.json");
248558
248662
  if (!await pathExists(tsconfigPath)) {
248559
248663
  return false;
248560
248664
  }
@@ -248597,7 +248701,7 @@ function getTypesCommand(context) {
248597
248701
  }
248598
248702
 
248599
248703
  // src/cli/dev/dev-server/main.ts
248600
- import { dirname as dirname13, join as join18 } from "node:path";
248704
+ import { dirname as dirname14, join as join20 } from "node:path";
248601
248705
  var import_cors = __toESM(require_lib4(), 1);
248602
248706
  var import_express4 = __toESM(require_express(), 1);
248603
248707
 
@@ -250077,9 +250181,9 @@ class NodeFsHandler {
250077
250181
  if (this.fsw.closed) {
250078
250182
  return;
250079
250183
  }
250080
- const dirname12 = sp2.dirname(file2);
250184
+ const dirname13 = sp2.dirname(file2);
250081
250185
  const basename5 = sp2.basename(file2);
250082
- const parent = this.fsw._getWatchedDir(dirname12);
250186
+ const parent = this.fsw._getWatchedDir(dirname13);
250083
250187
  let prevStats = stats;
250084
250188
  if (parent.has(basename5))
250085
250189
  return;
@@ -250106,7 +250210,7 @@ class NodeFsHandler {
250106
250210
  prevStats = newStats2;
250107
250211
  }
250108
250212
  } catch (error48) {
250109
- this.fsw._remove(dirname12, basename5);
250213
+ this.fsw._remove(dirname13, basename5);
250110
250214
  }
250111
250215
  } else if (parent.has(basename5)) {
250112
250216
  const at13 = newStats.atimeMs;
@@ -251127,8 +251231,8 @@ async function createDevServer(options8) {
251127
251231
  broadcastEntityEvent(io6, appId, entityName, event);
251128
251232
  };
251129
251233
  const base44ConfigWatcher = new WatchBase44({
251130
- functions: join18(dirname13(project2.configPath), project2.functionsDir),
251131
- entities: join18(dirname13(project2.configPath), project2.entitiesDir)
251234
+ functions: join20(dirname14(project2.configPath), project2.functionsDir),
251235
+ entities: join20(dirname14(project2.configPath), project2.entitiesDir)
251132
251236
  }, devLogger);
251133
251237
  base44ConfigWatcher.on("change", async (name2) => {
251134
251238
  try {
@@ -251318,7 +251422,7 @@ var import_detect_agent = __toESM(require_dist5(), 1);
251318
251422
  import { release, type } from "node:os";
251319
251423
 
251320
251424
  // ../../node_modules/posthog-node/dist/extensions/error-tracking/modifiers/module.node.mjs
251321
- import { dirname as dirname14, posix, sep } from "path";
251425
+ import { dirname as dirname15, posix, sep } from "path";
251322
251426
  function createModulerModifier() {
251323
251427
  const getModuleFromFileName = createGetModuleFromFilename();
251324
251428
  return async (frames) => {
@@ -251327,7 +251431,7 @@ function createModulerModifier() {
251327
251431
  return frames;
251328
251432
  };
251329
251433
  }
251330
- function createGetModuleFromFilename(basePath = process.argv[1] ? dirname14(process.argv[1]) : process.cwd(), isWindows5 = sep === "\\") {
251434
+ function createGetModuleFromFilename(basePath = process.argv[1] ? dirname15(process.argv[1]) : process.cwd(), isWindows5 = sep === "\\") {
251331
251435
  const normalizedBase = isWindows5 ? normalizeWindowsPath2(basePath) : basePath;
251332
251436
  return (filename) => {
251333
251437
  if (!filename)
@@ -255516,9 +255620,9 @@ function addCommandInfoToErrorReporter(program2, errorReporter) {
255516
255620
  });
255517
255621
  }
255518
255622
  // src/cli/index.ts
255519
- var __dirname4 = dirname15(fileURLToPath6(import.meta.url));
255623
+ var __dirname4 = dirname16(fileURLToPath6(import.meta.url));
255520
255624
  async function runCLI(options8) {
255521
- ensureNpmAssets(join19(__dirname4, "../assets"));
255625
+ ensureNpmAssets(join21(__dirname4, "../assets"));
255522
255626
  const errorReporter = new ErrorReporter;
255523
255627
  errorReporter.registerProcessErrorHandlers();
255524
255628
  const isNonInteractive = !process.stdin.isTTY || !process.stdout.isTTY;
@@ -255551,4 +255655,4 @@ export {
255551
255655
  CLIExitError
255552
255656
  };
255553
255657
 
255554
- //# debugId=2742D86806A6F2DB64756E2164756E21
255658
+ //# debugId=6D7955D702A30EFA64756E2164756E21