@base44-preview/cli 0.0.49-pr.370.093ccc2 → 0.0.49-pr.443.0146fb3

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
@@ -234565,15 +234565,11 @@ var SiteConfigSchema = exports_external.object({
234565
234565
  outputDirectory: exports_external.string().optional(),
234566
234566
  installCommand: exports_external.string().optional()
234567
234567
  });
234568
- var VisibilitySchema = exports_external.enum(["public", "private", "workspace"], {
234569
- error: 'Invalid visibility value. Allowed values: "public", "private", "workspace"'
234570
- });
234571
234568
  var ProjectConfigSchema = exports_external.object({
234572
234569
  name: exports_external.string({
234573
234570
  error: "App name cannot be empty"
234574
234571
  }).min(1, "App name cannot be empty"),
234575
234572
  description: exports_external.string().optional(),
234576
- visibility: VisibilitySchema.optional(),
234577
234573
  site: SiteConfigSchema.optional(),
234578
234574
  entitiesDir: exports_external.string().optional().default("entities"),
234579
234575
  functionsDir: exports_external.string().optional().default("functions"),
@@ -243069,7 +243065,7 @@ async function createProject(projectName, description) {
243069
243065
  name: projectName,
243070
243066
  user_description: description ?? `Backend for '${projectName}'`,
243071
243067
  is_managed_source_code: false,
243072
- public_settings: "private_with_login"
243068
+ public_settings: "public_without_login"
243073
243069
  }
243074
243070
  });
243075
243071
  } catch (error48) {
@@ -243083,23 +243079,6 @@ async function createProject(projectName, description) {
243083
243079
  projectId: result.data.id
243084
243080
  };
243085
243081
  }
243086
- var VISIBILITY_TO_PUBLIC_SETTINGS = {
243087
- public: "public_without_login",
243088
- private: "private_with_login",
243089
- workspace: "workspace_with_login"
243090
- };
243091
- async function updateProjectVisibility(visibility) {
243092
- const { id } = getAppConfig();
243093
- try {
243094
- await base44Client.put(`api/apps/${id}`, {
243095
- json: {
243096
- public_settings: VISIBILITY_TO_PUBLIC_SETTINGS[visibility]
243097
- }
243098
- });
243099
- } catch (error48) {
243100
- throw await ApiError.fromHttpError(error48, "updating project visibility");
243101
- }
243102
- }
243103
243082
  async function listProjects() {
243104
243083
  let response;
243105
243084
  try {
@@ -243433,9 +243412,6 @@ async function deployAll(projectData, options) {
243433
243412
  await agentResource.push(agents);
243434
243413
  await authConfigResource.push(authConfig);
243435
243414
  const { results: connectorResults } = await pushConnectors(connectors);
243436
- if (project.visibility) {
243437
- await updateProjectVisibility(project.visibility);
243438
- }
243439
243415
  if (project.site?.outputDirectory) {
243440
243416
  const outputDir = resolve(project.root, project.site.outputDirectory);
243441
243417
  const { appUrl } = await deploySite(outputDir);
@@ -252901,22 +252877,37 @@ var $setGracefulCleanup = tmp.setGracefulCleanup;
252901
252877
  var colorByType = {
252902
252878
  error: theme.styles.error,
252903
252879
  warn: theme.styles.warn,
252904
- log: (text) => text
252880
+ log: (input) => input
252881
+ };
252882
+ var stringify = (item) => {
252883
+ if (typeof item === "string") {
252884
+ return item;
252885
+ }
252886
+ if (item instanceof Error) {
252887
+ return item.toString();
252888
+ }
252889
+ try {
252890
+ return JSON.stringify(item) ?? String(item);
252891
+ } catch {
252892
+ return String(item);
252893
+ }
252905
252894
  };
252906
252895
  function createDevLogger() {
252907
- const print = (type, msg) => {
252896
+ const print = (type, ...args) => {
252908
252897
  const colorize = colorByType[type];
252909
- console[type](colorize(msg));
252898
+ console[type](...args.map((item) => {
252899
+ return colorize(stringify(item));
252900
+ }));
252910
252901
  };
252911
252902
  return {
252912
- log: (msg) => print("log", msg),
252903
+ log: (...args) => print("log", ...args),
252913
252904
  error: (msg, err) => {
252914
252905
  print("error", msg);
252915
252906
  if (err) {
252916
- print("error", String(err));
252907
+ print("error", err);
252917
252908
  }
252918
252909
  },
252919
- warn: (msg) => print("warn", msg)
252910
+ warn: (...args) => print("warn", ...args)
252920
252911
  };
252921
252912
  }
252922
252913
 
@@ -260151,4 +260142,4 @@ export {
260151
260142
  CLIExitError
260152
260143
  };
260153
260144
 
260154
- //# debugId=7ACE5F88D7EDD98A64756E2164756E21
260145
+ //# debugId=2BB24D9CB06D45A464756E2164756E21