@base44-preview/cli 0.0.17-pr.19.e5e923a → 0.0.17-pr.93.acb621a
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/README.md +0 -29
- package/dist/{index.js → cli/index.js} +104 -180
- package/package.json +9 -14
- package/bin/dev.cmd +0 -2
- package/bin/dev.js +0 -12
- package/bin/run.cmd +0 -2
- package/bin/run.js +0 -12
- /package/dist/{templates → cli/templates}/backend-and-client/.nvmrc +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/README.md +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/base44/app.jsonc.ejs +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/base44/config.jsonc.ejs +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/base44/entities/task.jsonc +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/components.json +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/index.html +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/jsconfig.json +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/package.json +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/postcss.config.js +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/App.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/api/base44Client.js.ejs +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/components/Base44Logo.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/components/ui/button.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/components/ui/checkbox.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/components/ui/input.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/index.css +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/src/main.jsx +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/tailwind.config.js +0 -0
- /package/dist/{templates → cli/templates}/backend-and-client/vite.config.js +0 -0
- /package/dist/{templates → cli/templates}/backend-only/base44/app.jsonc.ejs +0 -0
- /package/dist/{templates → cli/templates}/backend-only/base44/config.jsonc.ejs +0 -0
- /package/dist/{templates → cli/templates}/templates.json +0 -0
package/README.md
CHANGED
|
@@ -57,35 +57,6 @@ The CLI will guide you through project setup. For step-by-step tutorials, see th
|
|
|
57
57
|
|
|
58
58
|
<!--| [`eject`](https://docs.base44.com/developers/references/cli/commands/eject) | Create a Base44 backend project from an existing Base44 app | -->
|
|
59
59
|
|
|
60
|
-
## AI Agent Skills
|
|
61
|
-
|
|
62
|
-
When creating a project, you'll be prompted to install AI agent skills for your preferred coding assistants:
|
|
63
|
-
|
|
64
|
-
```
|
|
65
|
-
◆ Add AI agent skills? (Select agents to configure)
|
|
66
|
-
│ ◼ Cursor
|
|
67
|
-
│ ◼ Claude Code
|
|
68
|
-
└
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
This installs [base44/skills](https://github.com/base44/skills) which helps AI agents understand how to work with Base44 projects.
|
|
72
|
-
|
|
73
|
-
**Non-interactive mode:**
|
|
74
|
-
|
|
75
|
-
```bash
|
|
76
|
-
# Install skills for all supported agents
|
|
77
|
-
base44 create --name my-app --path ./my-app --skills
|
|
78
|
-
|
|
79
|
-
# Skip skills installation
|
|
80
|
-
base44 create --name my-app --path ./my-app
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
**Manual installation:**
|
|
84
|
-
|
|
85
|
-
```bash
|
|
86
|
-
npx add-skill base44/skills
|
|
87
|
-
```
|
|
88
|
-
|
|
89
60
|
## Help
|
|
90
61
|
|
|
91
62
|
```bash
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
1
2
|
import { createRequire } from "node:module";
|
|
2
3
|
import { EventEmitter, addAbortListener, on, once, setMaxListeners } from "node:events";
|
|
3
4
|
import childProcess, { ChildProcess, execFile, spawn, spawnSync } from "node:child_process";
|
|
4
5
|
import path, { basename, dirname, join, posix, resolve, win32 } from "node:path";
|
|
5
6
|
import fs, { appendFileSync, createReadStream, createWriteStream, readFileSync, statSync, writeFileSync } from "node:fs";
|
|
6
|
-
import
|
|
7
|
+
import process$1, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
|
|
7
8
|
import { aborted, callbackify, debuglog, inspect, promisify, stripVTControlCharacters } from "node:util";
|
|
8
9
|
import * as g from "node:readline";
|
|
9
10
|
import O from "node:readline";
|
|
@@ -893,7 +894,7 @@ var require_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
893
894
|
const childProcess$1 = __require("node:child_process");
|
|
894
895
|
const path$15 = __require("node:path");
|
|
895
896
|
const fs$10 = __require("node:fs");
|
|
896
|
-
const process$
|
|
897
|
+
const process$4 = __require("node:process");
|
|
897
898
|
const { Argument, humanReadableArgName } = require_argument();
|
|
898
899
|
const { CommanderError } = require_error$1();
|
|
899
900
|
const { Help } = require_help();
|
|
@@ -944,10 +945,10 @@ var require_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
944
945
|
this._showHelpAfterError = false;
|
|
945
946
|
this._showSuggestionAfterError = true;
|
|
946
947
|
this._outputConfiguration = {
|
|
947
|
-
writeOut: (str) => process$
|
|
948
|
-
writeErr: (str) => process$
|
|
949
|
-
getOutHelpWidth: () => process$
|
|
950
|
-
getErrHelpWidth: () => process$
|
|
948
|
+
writeOut: (str) => process$4.stdout.write(str),
|
|
949
|
+
writeErr: (str) => process$4.stderr.write(str),
|
|
950
|
+
getOutHelpWidth: () => process$4.stdout.isTTY ? process$4.stdout.columns : void 0,
|
|
951
|
+
getErrHelpWidth: () => process$4.stderr.isTTY ? process$4.stderr.columns : void 0,
|
|
951
952
|
outputError: (str, write) => write(str)
|
|
952
953
|
};
|
|
953
954
|
this._hidden = false;
|
|
@@ -1301,7 +1302,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1301
1302
|
*/
|
|
1302
1303
|
_exit(exitCode, code$1, message) {
|
|
1303
1304
|
if (this._exitCallback) this._exitCallback(new CommanderError(exitCode, code$1, message));
|
|
1304
|
-
process$
|
|
1305
|
+
process$4.exit(exitCode);
|
|
1305
1306
|
}
|
|
1306
1307
|
/**
|
|
1307
1308
|
* Register callback `fn` for the command.
|
|
@@ -1640,11 +1641,11 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1640
1641
|
if (argv !== void 0 && !Array.isArray(argv)) throw new Error("first parameter to parse must be array or undefined");
|
|
1641
1642
|
parseOptions = parseOptions || {};
|
|
1642
1643
|
if (argv === void 0 && parseOptions.from === void 0) {
|
|
1643
|
-
if (process$
|
|
1644
|
-
const execArgv$1 = process$
|
|
1644
|
+
if (process$4.versions?.electron) parseOptions.from = "electron";
|
|
1645
|
+
const execArgv$1 = process$4.execArgv ?? [];
|
|
1645
1646
|
if (execArgv$1.includes("-e") || execArgv$1.includes("--eval") || execArgv$1.includes("-p") || execArgv$1.includes("--print")) parseOptions.from = "eval";
|
|
1646
1647
|
}
|
|
1647
|
-
if (argv === void 0) argv = process$
|
|
1648
|
+
if (argv === void 0) argv = process$4.argv;
|
|
1648
1649
|
this.rawArgs = argv.slice();
|
|
1649
1650
|
let userArgs;
|
|
1650
1651
|
switch (parseOptions.from) {
|
|
@@ -1654,7 +1655,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1654
1655
|
userArgs = argv.slice(2);
|
|
1655
1656
|
break;
|
|
1656
1657
|
case "electron":
|
|
1657
|
-
if (process$
|
|
1658
|
+
if (process$4.defaultApp) {
|
|
1658
1659
|
this._scriptPath = argv[1];
|
|
1659
1660
|
userArgs = argv.slice(2);
|
|
1660
1661
|
} else userArgs = argv.slice(1);
|
|
@@ -1768,15 +1769,15 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1768
1769
|
}
|
|
1769
1770
|
launchWithNode = sourceExt.includes(path$15.extname(executableFile));
|
|
1770
1771
|
let proc$1;
|
|
1771
|
-
if (process$
|
|
1772
|
+
if (process$4.platform !== "win32") if (launchWithNode) {
|
|
1772
1773
|
args.unshift(executableFile);
|
|
1773
|
-
args = incrementNodeInspectorPort(process$
|
|
1774
|
-
proc$1 = childProcess$1.spawn(process$
|
|
1774
|
+
args = incrementNodeInspectorPort(process$4.execArgv).concat(args);
|
|
1775
|
+
proc$1 = childProcess$1.spawn(process$4.argv[0], args, { stdio: "inherit" });
|
|
1775
1776
|
} else proc$1 = childProcess$1.spawn(executableFile, args, { stdio: "inherit" });
|
|
1776
1777
|
else {
|
|
1777
1778
|
args.unshift(executableFile);
|
|
1778
|
-
args = incrementNodeInspectorPort(process$
|
|
1779
|
-
proc$1 = childProcess$1.spawn(process$
|
|
1779
|
+
args = incrementNodeInspectorPort(process$4.execArgv).concat(args);
|
|
1780
|
+
proc$1 = childProcess$1.spawn(process$4.execPath, args, { stdio: "inherit" });
|
|
1780
1781
|
}
|
|
1781
1782
|
if (!proc$1.killed) [
|
|
1782
1783
|
"SIGUSR1",
|
|
@@ -1785,14 +1786,14 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1785
1786
|
"SIGINT",
|
|
1786
1787
|
"SIGHUP"
|
|
1787
1788
|
].forEach((signal) => {
|
|
1788
|
-
process$
|
|
1789
|
+
process$4.on(signal, () => {
|
|
1789
1790
|
if (proc$1.killed === false && proc$1.exitCode === null) proc$1.kill(signal);
|
|
1790
1791
|
});
|
|
1791
1792
|
});
|
|
1792
1793
|
const exitCallback = this._exitCallback;
|
|
1793
1794
|
proc$1.on("close", (code$1) => {
|
|
1794
1795
|
code$1 = code$1 ?? 1;
|
|
1795
|
-
if (!exitCallback) process$
|
|
1796
|
+
if (!exitCallback) process$4.exit(code$1);
|
|
1796
1797
|
else exitCallback(new CommanderError(code$1, "commander.executeSubCommandAsync", "(close)"));
|
|
1797
1798
|
});
|
|
1798
1799
|
proc$1.on("error", (err) => {
|
|
@@ -1804,7 +1805,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
1804
1805
|
- ${executableDirMessage}`;
|
|
1805
1806
|
throw new Error(executableMissing);
|
|
1806
1807
|
} else if (err.code === "EACCES") throw new Error(`'${executableFile}' not executable`);
|
|
1807
|
-
if (!exitCallback) process$
|
|
1808
|
+
if (!exitCallback) process$4.exit(1);
|
|
1808
1809
|
else {
|
|
1809
1810
|
const wrappedError = new CommanderError(1, "commander.executeSubCommandAsync", "(error)");
|
|
1810
1811
|
wrappedError.nestedError = err;
|
|
@@ -2210,13 +2211,13 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
2210
2211
|
*/
|
|
2211
2212
|
_parseOptionsEnv() {
|
|
2212
2213
|
this.options.forEach((option) => {
|
|
2213
|
-
if (option.envVar && option.envVar in process$
|
|
2214
|
+
if (option.envVar && option.envVar in process$4.env) {
|
|
2214
2215
|
const optionKey = option.attributeName();
|
|
2215
2216
|
if (this.getOptionValue(optionKey) === void 0 || [
|
|
2216
2217
|
"default",
|
|
2217
2218
|
"config",
|
|
2218
2219
|
"env"
|
|
2219
|
-
].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$
|
|
2220
|
+
].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$4.env[option.envVar]);
|
|
2220
2221
|
else this.emit(`optionEnv:${option.name()}`);
|
|
2221
2222
|
}
|
|
2222
2223
|
});
|
|
@@ -2595,7 +2596,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
2595
2596
|
*/
|
|
2596
2597
|
help(contextOptions) {
|
|
2597
2598
|
this.outputHelp(contextOptions);
|
|
2598
|
-
let exitCode = process$
|
|
2599
|
+
let exitCode = process$4.exitCode || 0;
|
|
2599
2600
|
if (exitCode === 0 && contextOptions && typeof contextOptions !== "function" && contextOptions.error) exitCode = 1;
|
|
2600
2601
|
this._exit(exitCode, "commander.help", "(outputHelp)");
|
|
2601
2602
|
}
|
|
@@ -2711,16 +2712,16 @@ var require_src = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
2711
2712
|
const CSI = `${ESC}[`;
|
|
2712
2713
|
const beep = "\x07";
|
|
2713
2714
|
const cursor = {
|
|
2714
|
-
to(x$2, y$
|
|
2715
|
-
if (!y$
|
|
2716
|
-
return `${CSI}${y$
|
|
2715
|
+
to(x$2, y$1) {
|
|
2716
|
+
if (!y$1) return `${CSI}${x$2 + 1}G`;
|
|
2717
|
+
return `${CSI}${y$1 + 1};${x$2 + 1}H`;
|
|
2717
2718
|
},
|
|
2718
|
-
move(x$2, y$
|
|
2719
|
+
move(x$2, y$1) {
|
|
2719
2720
|
let ret = "";
|
|
2720
2721
|
if (x$2 < 0) ret += `${CSI}${-x$2}D`;
|
|
2721
2722
|
else if (x$2 > 0) ret += `${CSI}${x$2}C`;
|
|
2722
|
-
if (y$
|
|
2723
|
-
else if (y$
|
|
2723
|
+
if (y$1 < 0) ret += `${CSI}${-y$1}A`;
|
|
2724
|
+
else if (y$1 > 0) ret += `${CSI}${y$1}B`;
|
|
2724
2725
|
return ret;
|
|
2725
2726
|
},
|
|
2726
2727
|
up: (count$1 = 1) => `${CSI}${count$1}A`,
|
|
@@ -3030,13 +3031,13 @@ function rD() {
|
|
|
3030
3031
|
}
|
|
3031
3032
|
}), r;
|
|
3032
3033
|
}
|
|
3033
|
-
const ED = rD(), d$1 = new Set(["\x1B", ""]), oD = 39, y
|
|
3034
|
+
const ED = rD(), d$1 = new Set(["\x1B", ""]), oD = 39, y = "\x07", V$1 = "[", nD = "]", G$1 = "m", _$1 = `${nD}8;;`, z = (e$1) => `${d$1.values().next().value}${V$1}${e$1}${G$1}`, K$1 = (e$1) => `${d$1.values().next().value}${_$1}${e$1}${y}`, aD = (e$1) => e$1.split(" ").map((u$2) => p(u$2)), k$1 = (e$1, u$2, t) => {
|
|
3034
3035
|
const F$1 = [...u$2];
|
|
3035
3036
|
let s = !1, i$1 = !1, D$1 = p(P$1(e$1[e$1.length - 1]));
|
|
3036
3037
|
for (const [C$1, n$1] of F$1.entries()) {
|
|
3037
3038
|
const E = p(n$1);
|
|
3038
3039
|
if (D$1 + E <= t ? e$1[e$1.length - 1] += n$1 : (e$1.push(n$1), D$1 = 0), d$1.has(n$1) && (s = !0, i$1 = F$1.slice(C$1 + 1).join("").startsWith(_$1)), s) {
|
|
3039
|
-
i$1 ? n$1 === y
|
|
3040
|
+
i$1 ? n$1 === y && (s = !1, i$1 = !1) : n$1 === G$1 && (s = !1);
|
|
3040
3041
|
continue;
|
|
3041
3042
|
}
|
|
3042
3043
|
D$1 += E, D$1 === t && C$1 < F$1.length - 1 && (e$1.push(""), D$1 = 0);
|
|
@@ -3078,7 +3079,7 @@ const ED = rD(), d$1 = new Set(["\x1B", ""]), oD = 39, y$1 = "\x07", V$1 = "["
|
|
|
3078
3079
|
`)];
|
|
3079
3080
|
for (const [E, a$1] of n$1.entries()) {
|
|
3080
3081
|
if (F$1 += a$1, d$1.has(a$1)) {
|
|
3081
|
-
const { groups: c$1 } = (/* @__PURE__ */ new RegExp(`(?:\\${V$1}(?<code>\\d+)m|\\${_$1}(?<uri>.*)${y
|
|
3082
|
+
const { groups: c$1 } = (/* @__PURE__ */ new RegExp(`(?:\\${V$1}(?<code>\\d+)m|\\${_$1}(?<uri>.*)${y})`)).exec(n$1.slice(E).join("")) || { groups: {} };
|
|
3082
3083
|
if (c$1.code !== void 0) {
|
|
3083
3084
|
const f = Number.parseFloat(c$1.code);
|
|
3084
3085
|
s = f === oD ? void 0 : f;
|
|
@@ -3479,7 +3480,7 @@ var RD = class extends x$1 {
|
|
|
3479
3480
|
//#endregion
|
|
3480
3481
|
//#region node_modules/@clack/prompts/dist/index.mjs
|
|
3481
3482
|
function ce() {
|
|
3482
|
-
return
|
|
3483
|
+
return process$1.platform !== "win32" ? process$1.env.TERM !== "linux" : !!process$1.env.CI || !!process$1.env.WT_SESSION || !!process$1.env.TERMINUS_SUBLIME || process$1.env.ConEmuTask === "{cmd::Cmder}" || process$1.env.TERM_PROGRAM === "Terminus-Sublime" || process$1.env.TERM_PROGRAM === "vscode" || process$1.env.TERM === "xterm-256color" || process$1.env.TERM === "alacritty" || process$1.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
3483
3484
|
}
|
|
3484
3485
|
const V = ce(), u$1 = (t, n$1) => V ? t : n$1, le = u$1("◆", "*"), L = u$1("■", "x"), W = u$1("▲", "x"), C = u$1("◇", "o"), ue = u$1("┌", "T"), o$1 = u$1("│", "|"), d = u$1("└", "—"), k = u$1("●", ">"), P = u$1("○", " "), A = u$1("◻", "[•]"), T = u$1("◼", "[+]"), F = u$1("◻", "[ ]"), $e = u$1("▪", "•"), _ = u$1("─", "-"), me = u$1("╮", "+"), de = u$1("├", "+"), pe = u$1("╯", "+"), q = u$1("●", "•"), D = u$1("◆", "*"), U = u$1("▲", "!"), K = u$1("■", "x"), b = (t) => {
|
|
3485
3486
|
switch (t) {
|
|
@@ -6653,7 +6654,7 @@ function initializeContext(params) {
|
|
|
6653
6654
|
external: params?.external ?? void 0
|
|
6654
6655
|
};
|
|
6655
6656
|
}
|
|
6656
|
-
function process$
|
|
6657
|
+
function process$3(schema, ctx, _params = {
|
|
6657
6658
|
path: [],
|
|
6658
6659
|
schemaPath: []
|
|
6659
6660
|
}) {
|
|
@@ -6690,7 +6691,7 @@ function process$2(schema, ctx, _params = {
|
|
|
6690
6691
|
const parent = schema._zod.parent;
|
|
6691
6692
|
if (parent) {
|
|
6692
6693
|
if (!result.ref) result.ref = parent;
|
|
6693
|
-
process$
|
|
6694
|
+
process$3(parent, ctx, params);
|
|
6694
6695
|
ctx.seen.get(parent).isParent = true;
|
|
6695
6696
|
}
|
|
6696
6697
|
}
|
|
@@ -6902,7 +6903,7 @@ const createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
|
|
|
6902
6903
|
...params,
|
|
6903
6904
|
processors
|
|
6904
6905
|
});
|
|
6905
|
-
process$
|
|
6906
|
+
process$3(schema, ctx);
|
|
6906
6907
|
extractDefs(ctx, schema);
|
|
6907
6908
|
return finalize(ctx, schema);
|
|
6908
6909
|
};
|
|
@@ -6914,7 +6915,7 @@ const createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params)
|
|
|
6914
6915
|
io,
|
|
6915
6916
|
processors
|
|
6916
6917
|
});
|
|
6917
|
-
process$
|
|
6918
|
+
process$3(schema, ctx);
|
|
6918
6919
|
extractDefs(ctx, schema);
|
|
6919
6920
|
return finalize(ctx, schema);
|
|
6920
6921
|
};
|
|
@@ -7001,7 +7002,7 @@ const arrayProcessor = (schema, ctx, _json, params) => {
|
|
|
7001
7002
|
if (typeof minimum === "number") json.minItems = minimum;
|
|
7002
7003
|
if (typeof maximum === "number") json.maxItems = maximum;
|
|
7003
7004
|
json.type = "array";
|
|
7004
|
-
json.items = process$
|
|
7005
|
+
json.items = process$3(def.element, ctx, {
|
|
7005
7006
|
...params,
|
|
7006
7007
|
path: [...params.path, "items"]
|
|
7007
7008
|
});
|
|
@@ -7012,7 +7013,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
7012
7013
|
json.type = "object";
|
|
7013
7014
|
json.properties = {};
|
|
7014
7015
|
const shape = def.shape;
|
|
7015
|
-
for (const key in shape) json.properties[key] = process$
|
|
7016
|
+
for (const key in shape) json.properties[key] = process$3(shape[key], ctx, {
|
|
7016
7017
|
...params,
|
|
7017
7018
|
path: [
|
|
7018
7019
|
...params.path,
|
|
@@ -7030,7 +7031,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
7030
7031
|
if (def.catchall?._zod.def.type === "never") json.additionalProperties = false;
|
|
7031
7032
|
else if (!def.catchall) {
|
|
7032
7033
|
if (ctx.io === "output") json.additionalProperties = false;
|
|
7033
|
-
} else if (def.catchall) json.additionalProperties = process$
|
|
7034
|
+
} else if (def.catchall) json.additionalProperties = process$3(def.catchall, ctx, {
|
|
7034
7035
|
...params,
|
|
7035
7036
|
path: [...params.path, "additionalProperties"]
|
|
7036
7037
|
});
|
|
@@ -7038,7 +7039,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
7038
7039
|
const unionProcessor = (schema, ctx, json, params) => {
|
|
7039
7040
|
const def = schema._zod.def;
|
|
7040
7041
|
const isExclusive = def.inclusive === false;
|
|
7041
|
-
const options = def.options.map((x$2, i$1) => process$
|
|
7042
|
+
const options = def.options.map((x$2, i$1) => process$3(x$2, ctx, {
|
|
7042
7043
|
...params,
|
|
7043
7044
|
path: [
|
|
7044
7045
|
...params.path,
|
|
@@ -7051,7 +7052,7 @@ const unionProcessor = (schema, ctx, json, params) => {
|
|
|
7051
7052
|
};
|
|
7052
7053
|
const intersectionProcessor = (schema, ctx, json, params) => {
|
|
7053
7054
|
const def = schema._zod.def;
|
|
7054
|
-
const a$1 = process$
|
|
7055
|
+
const a$1 = process$3(def.left, ctx, {
|
|
7055
7056
|
...params,
|
|
7056
7057
|
path: [
|
|
7057
7058
|
...params.path,
|
|
@@ -7059,7 +7060,7 @@ const intersectionProcessor = (schema, ctx, json, params) => {
|
|
|
7059
7060
|
0
|
|
7060
7061
|
]
|
|
7061
7062
|
});
|
|
7062
|
-
const b$2 = process$
|
|
7063
|
+
const b$2 = process$3(def.right, ctx, {
|
|
7063
7064
|
...params,
|
|
7064
7065
|
path: [
|
|
7065
7066
|
...params.path,
|
|
@@ -7076,7 +7077,7 @@ const tupleProcessor = (schema, ctx, _json, params) => {
|
|
|
7076
7077
|
json.type = "array";
|
|
7077
7078
|
const prefixPath$1 = ctx.target === "draft-2020-12" ? "prefixItems" : "items";
|
|
7078
7079
|
const restPath = ctx.target === "draft-2020-12" ? "items" : ctx.target === "openapi-3.0" ? "items" : "additionalItems";
|
|
7079
|
-
const prefixItems = def.items.map((x$2, i$1) => process$
|
|
7080
|
+
const prefixItems = def.items.map((x$2, i$1) => process$3(x$2, ctx, {
|
|
7080
7081
|
...params,
|
|
7081
7082
|
path: [
|
|
7082
7083
|
...params.path,
|
|
@@ -7084,7 +7085,7 @@ const tupleProcessor = (schema, ctx, _json, params) => {
|
|
|
7084
7085
|
i$1
|
|
7085
7086
|
]
|
|
7086
7087
|
}));
|
|
7087
|
-
const rest = def.rest ? process$
|
|
7088
|
+
const rest = def.rest ? process$3(def.rest, ctx, {
|
|
7088
7089
|
...params,
|
|
7089
7090
|
path: [
|
|
7090
7091
|
...params.path,
|
|
@@ -7110,7 +7111,7 @@ const tupleProcessor = (schema, ctx, _json, params) => {
|
|
|
7110
7111
|
};
|
|
7111
7112
|
const nullableProcessor = (schema, ctx, json, params) => {
|
|
7112
7113
|
const def = schema._zod.def;
|
|
7113
|
-
const inner = process$
|
|
7114
|
+
const inner = process$3(def.innerType, ctx, params);
|
|
7114
7115
|
const seen = ctx.seen.get(schema);
|
|
7115
7116
|
if (ctx.target === "openapi-3.0") {
|
|
7116
7117
|
seen.ref = def.innerType;
|
|
@@ -7119,27 +7120,27 @@ const nullableProcessor = (schema, ctx, json, params) => {
|
|
|
7119
7120
|
};
|
|
7120
7121
|
const nonoptionalProcessor = (schema, ctx, _json, params) => {
|
|
7121
7122
|
const def = schema._zod.def;
|
|
7122
|
-
process$
|
|
7123
|
+
process$3(def.innerType, ctx, params);
|
|
7123
7124
|
const seen = ctx.seen.get(schema);
|
|
7124
7125
|
seen.ref = def.innerType;
|
|
7125
7126
|
};
|
|
7126
7127
|
const defaultProcessor = (schema, ctx, json, params) => {
|
|
7127
7128
|
const def = schema._zod.def;
|
|
7128
|
-
process$
|
|
7129
|
+
process$3(def.innerType, ctx, params);
|
|
7129
7130
|
const seen = ctx.seen.get(schema);
|
|
7130
7131
|
seen.ref = def.innerType;
|
|
7131
7132
|
json.default = JSON.parse(JSON.stringify(def.defaultValue));
|
|
7132
7133
|
};
|
|
7133
7134
|
const prefaultProcessor = (schema, ctx, json, params) => {
|
|
7134
7135
|
const def = schema._zod.def;
|
|
7135
|
-
process$
|
|
7136
|
+
process$3(def.innerType, ctx, params);
|
|
7136
7137
|
const seen = ctx.seen.get(schema);
|
|
7137
7138
|
seen.ref = def.innerType;
|
|
7138
7139
|
if (ctx.io === "input") json._prefault = JSON.parse(JSON.stringify(def.defaultValue));
|
|
7139
7140
|
};
|
|
7140
7141
|
const catchProcessor = (schema, ctx, json, params) => {
|
|
7141
7142
|
const def = schema._zod.def;
|
|
7142
|
-
process$
|
|
7143
|
+
process$3(def.innerType, ctx, params);
|
|
7143
7144
|
const seen = ctx.seen.get(schema);
|
|
7144
7145
|
seen.ref = def.innerType;
|
|
7145
7146
|
let catchValue;
|
|
@@ -7153,20 +7154,20 @@ const catchProcessor = (schema, ctx, json, params) => {
|
|
|
7153
7154
|
const pipeProcessor = (schema, ctx, _json, params) => {
|
|
7154
7155
|
const def = schema._zod.def;
|
|
7155
7156
|
const innerType = ctx.io === "input" ? def.in._zod.def.type === "transform" ? def.out : def.in : def.out;
|
|
7156
|
-
process$
|
|
7157
|
+
process$3(innerType, ctx, params);
|
|
7157
7158
|
const seen = ctx.seen.get(schema);
|
|
7158
7159
|
seen.ref = innerType;
|
|
7159
7160
|
};
|
|
7160
7161
|
const readonlyProcessor = (schema, ctx, json, params) => {
|
|
7161
7162
|
const def = schema._zod.def;
|
|
7162
|
-
process$
|
|
7163
|
+
process$3(def.innerType, ctx, params);
|
|
7163
7164
|
const seen = ctx.seen.get(schema);
|
|
7164
7165
|
seen.ref = def.innerType;
|
|
7165
7166
|
json.readOnly = true;
|
|
7166
7167
|
};
|
|
7167
7168
|
const optionalProcessor = (schema, ctx, _json, params) => {
|
|
7168
7169
|
const def = schema._zod.def;
|
|
7169
|
-
process$
|
|
7170
|
+
process$3(def.innerType, ctx, params);
|
|
7170
7171
|
const seen = ctx.seen.get(schema);
|
|
7171
7172
|
seen.ref = def.innerType;
|
|
7172
7173
|
};
|
|
@@ -16192,7 +16193,7 @@ const createIgnorePredicate = (patterns, cwd, baseDir) => {
|
|
|
16192
16193
|
};
|
|
16193
16194
|
const normalizeOptions$2 = (options = {}) => {
|
|
16194
16195
|
const ignoreOption = options.ignore ? Array.isArray(options.ignore) ? options.ignore : [options.ignore] : [];
|
|
16195
|
-
const cwd = toPath$1(options.cwd) ??
|
|
16196
|
+
const cwd = toPath$1(options.cwd) ?? process$1.cwd();
|
|
16196
16197
|
const deep = typeof options.deep === "number" ? Math.max(0, options.deep) + 1 : Number.POSITIVE_INFINITY;
|
|
16197
16198
|
return {
|
|
16198
16199
|
cwd,
|
|
@@ -16289,7 +16290,7 @@ const getDirectoryGlob = ({ directoryPath, files, extensions }) => {
|
|
|
16289
16290
|
const extensionGlob = extensions?.length > 0 ? `.${extensions.length > 1 ? `{${extensions.join(",")}}` : extensions[0]}` : "";
|
|
16290
16291
|
return files ? files.map((file) => path.posix.join(directoryPath, `**/${path.extname(file) ? file : `${file}${extensionGlob}`}`)) : [path.posix.join(directoryPath, `**${extensionGlob ? `/*${extensionGlob}` : ""}`)];
|
|
16291
16292
|
};
|
|
16292
|
-
const directoryToGlob = async (directoryPaths, { cwd =
|
|
16293
|
+
const directoryToGlob = async (directoryPaths, { cwd = process$1.cwd(), files, extensions, fs: fsImplementation } = {}) => {
|
|
16293
16294
|
return (await Promise.all(directoryPaths.map(async (directoryPath) => {
|
|
16294
16295
|
if (shouldExpandGlobstarDirectory(isNegativePattern(directoryPath) ? directoryPath.slice(1) : directoryPath)) return getDirectoryGlob({
|
|
16295
16296
|
directoryPath,
|
|
@@ -16303,7 +16304,7 @@ const directoryToGlob = async (directoryPaths, { cwd = y.cwd(), files, extension
|
|
|
16303
16304
|
}) : directoryPath;
|
|
16304
16305
|
}))).flat();
|
|
16305
16306
|
};
|
|
16306
|
-
const directoryToGlobSync = (directoryPaths, { cwd =
|
|
16307
|
+
const directoryToGlobSync = (directoryPaths, { cwd = process$1.cwd(), files, extensions, fs: fsImplementation } = {}) => directoryPaths.flatMap((directoryPath) => {
|
|
16307
16308
|
if (shouldExpandGlobstarDirectory(isNegativePattern(directoryPath) ? directoryPath.slice(1) : directoryPath)) return getDirectoryGlob({
|
|
16308
16309
|
directoryPath,
|
|
16309
16310
|
files,
|
|
@@ -16399,7 +16400,7 @@ const applyIgnoreFilesAndGetFilterSync = (options) => {
|
|
|
16399
16400
|
};
|
|
16400
16401
|
const createFilterFunction = (isIgnored, cwd) => {
|
|
16401
16402
|
const seen = /* @__PURE__ */ new Set();
|
|
16402
|
-
const basePath = cwd ||
|
|
16403
|
+
const basePath = cwd || process$1.cwd();
|
|
16403
16404
|
const pathCache = /* @__PURE__ */ new Map();
|
|
16404
16405
|
return (fastGlobResult) => {
|
|
16405
16406
|
const pathKey$1 = path.normalize(fastGlobResult.path ?? fastGlobResult);
|
|
@@ -30402,31 +30403,11 @@ async function deployAll(projectData) {
|
|
|
30402
30403
|
//#region src/core/project/app-config.ts
|
|
30403
30404
|
let cache = null;
|
|
30404
30405
|
/**
|
|
30405
|
-
* Load app config from BASE44_CLI_TEST_OVERRIDES env var.
|
|
30406
|
-
* @returns true if override was applied, false otherwise
|
|
30407
|
-
*/
|
|
30408
|
-
function loadFromTestOverrides() {
|
|
30409
|
-
const overrides = process.env.BASE44_CLI_TEST_OVERRIDES;
|
|
30410
|
-
if (!overrides) return false;
|
|
30411
|
-
try {
|
|
30412
|
-
const data = JSON.parse(overrides);
|
|
30413
|
-
if (data.appConfig?.id && data.appConfig?.projectRoot) {
|
|
30414
|
-
cache = {
|
|
30415
|
-
id: data.appConfig.id,
|
|
30416
|
-
projectRoot: data.appConfig.projectRoot
|
|
30417
|
-
};
|
|
30418
|
-
return true;
|
|
30419
|
-
}
|
|
30420
|
-
} catch {}
|
|
30421
|
-
return false;
|
|
30422
|
-
}
|
|
30423
|
-
/**
|
|
30424
30406
|
* Initialize app config by reading from .app.jsonc.
|
|
30425
30407
|
* Must be called before using getAppConfig().
|
|
30426
30408
|
* @throws Error if no project found or .app.jsonc missing
|
|
30427
30409
|
*/
|
|
30428
30410
|
async function initAppConfig() {
|
|
30429
|
-
if (loadFromTestOverrides()) return;
|
|
30430
30411
|
if (cache) return;
|
|
30431
30412
|
const projectRoot = await findProjectRoot();
|
|
30432
30413
|
if (!projectRoot) throw new Error("No Base44 project found. Run this command from a project directory with a config.jsonc file.");
|
|
@@ -30605,21 +30586,6 @@ async function getUserInfo(accessToken) {
|
|
|
30605
30586
|
return result.data;
|
|
30606
30587
|
}
|
|
30607
30588
|
|
|
30608
|
-
//#endregion
|
|
30609
|
-
//#region src/cli/errors.ts
|
|
30610
|
-
/**
|
|
30611
|
-
* Error thrown to signal a controlled CLI exit with a specific exit code.
|
|
30612
|
-
* This allows proper error propagation without calling process.exit() directly,
|
|
30613
|
-
* making the code more testable and maintaining a single exit point.
|
|
30614
|
-
*/
|
|
30615
|
-
var CLIExitError = class extends Error {
|
|
30616
|
-
constructor(code$1) {
|
|
30617
|
-
super(`CLI exited with code ${code$1}`);
|
|
30618
|
-
this.code = code$1;
|
|
30619
|
-
this.name = "CLIExitError";
|
|
30620
|
-
}
|
|
30621
|
-
};
|
|
30622
|
-
|
|
30623
30589
|
//#endregion
|
|
30624
30590
|
//#region node_modules/chalk/source/vendor/ansi-styles/index.js
|
|
30625
30591
|
const ANSI_BACKGROUND_OFFSET = 10;
|
|
@@ -30788,13 +30754,13 @@ var ansi_styles_default = ansiStyles;
|
|
|
30788
30754
|
|
|
30789
30755
|
//#endregion
|
|
30790
30756
|
//#region node_modules/chalk/source/vendor/supports-color/index.js
|
|
30791
|
-
function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args :
|
|
30757
|
+
function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : process$1.argv) {
|
|
30792
30758
|
const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
|
|
30793
30759
|
const position = argv.indexOf(prefix + flag);
|
|
30794
30760
|
const terminatorPosition = argv.indexOf("--");
|
|
30795
30761
|
return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
|
|
30796
30762
|
}
|
|
30797
|
-
const { env } =
|
|
30763
|
+
const { env } = process$1;
|
|
30798
30764
|
let flagForceColor;
|
|
30799
30765
|
if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) flagForceColor = 0;
|
|
30800
30766
|
else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) flagForceColor = 1;
|
|
@@ -30827,7 +30793,7 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
|
|
|
30827
30793
|
if (haveStream && !streamIsTTY && forceColor === void 0) return 0;
|
|
30828
30794
|
const min = forceColor || 0;
|
|
30829
30795
|
if (env.TERM === "dumb") return min;
|
|
30830
|
-
if (
|
|
30796
|
+
if (process$1.platform === "win32") {
|
|
30831
30797
|
const osRelease = os.release().split(".");
|
|
30832
30798
|
if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
|
|
30833
30799
|
return 1;
|
|
@@ -31186,7 +31152,7 @@ async function runCommand(commandFn, options) {
|
|
|
31186
31152
|
} catch (e$1) {
|
|
31187
31153
|
if (e$1 instanceof Error) M.error(e$1.stack ?? e$1.message);
|
|
31188
31154
|
else M.error(String(e$1));
|
|
31189
|
-
|
|
31155
|
+
process.exit(1);
|
|
31190
31156
|
}
|
|
31191
31157
|
}
|
|
31192
31158
|
|
|
@@ -31356,8 +31322,7 @@ const logoutCommand = new Command("logout").description("Logout from current dev
|
|
|
31356
31322
|
async function pushEntitiesAction() {
|
|
31357
31323
|
const { entities } = await readProjectConfig();
|
|
31358
31324
|
if (entities.length === 0) return { outroMessage: "No entities found in project" };
|
|
31359
|
-
|
|
31360
|
-
M.info(`Found ${entities.length} entities to push: ${entityNames}`);
|
|
31325
|
+
M.info(`Found ${entities.length} entities to push`);
|
|
31361
31326
|
const result = await runTask("Pushing entities to Base44", async () => {
|
|
31362
31327
|
return await pushEntities(entities);
|
|
31363
31328
|
}, {
|
|
@@ -31567,9 +31532,9 @@ const getSubprocessResult = ({ stdout: stdout$1 }) => {
|
|
|
31567
31532
|
//#region node_modules/execa/lib/utils/standard-stream.js
|
|
31568
31533
|
const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
|
|
31569
31534
|
const STANDARD_STREAMS = [
|
|
31570
|
-
|
|
31571
|
-
|
|
31572
|
-
|
|
31535
|
+
process$1.stdin,
|
|
31536
|
+
process$1.stdout,
|
|
31537
|
+
process$1.stderr
|
|
31573
31538
|
];
|
|
31574
31539
|
const STANDARD_STREAMS_ALIASES = [
|
|
31575
31540
|
"stdin",
|
|
@@ -31694,9 +31659,9 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
|
|
|
31694
31659
|
//#endregion
|
|
31695
31660
|
//#region node_modules/is-unicode-supported/index.js
|
|
31696
31661
|
function isUnicodeSupported() {
|
|
31697
|
-
const { env: env$1 } =
|
|
31662
|
+
const { env: env$1 } = process$1;
|
|
31698
31663
|
const { TERM, TERM_PROGRAM } = env$1;
|
|
31699
|
-
if (
|
|
31664
|
+
if (process$1.platform !== "win32") return TERM !== "linux";
|
|
31700
31665
|
return Boolean(env$1.WT_SESSION) || Boolean(env$1.TERMINUS_SUBLIME) || env$1.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env$1.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
31701
31666
|
}
|
|
31702
31667
|
|
|
@@ -32623,7 +32588,7 @@ const TEN_MEGABYTES_IN_BYTES = 10 * 1024 * 1024;
|
|
|
32623
32588
|
|
|
32624
32589
|
//#endregion
|
|
32625
32590
|
//#region node_modules/npm-run-path/index.js
|
|
32626
|
-
const npmRunPath = ({ cwd =
|
|
32591
|
+
const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath: execPath$1 = process$1.execPath, addExecPath = true } = {}) => {
|
|
32627
32592
|
const cwdPath = path.resolve(toPath(cwd));
|
|
32628
32593
|
const result = [];
|
|
32629
32594
|
const pathParts = pathOption.split(path.delimiter);
|
|
@@ -32641,7 +32606,7 @@ const applyExecPath = (result, pathParts, execPath$1, cwdPath) => {
|
|
|
32641
32606
|
const pathPart = path.resolve(cwdPath, toPath(execPath$1), "..");
|
|
32642
32607
|
if (!pathParts.includes(pathPart)) result.push(pathPart);
|
|
32643
32608
|
};
|
|
32644
|
-
const npmRunPathEnv = ({ env: env$1 =
|
|
32609
|
+
const npmRunPathEnv = ({ env: env$1 = process$1.env, ...options } = {}) => {
|
|
32645
32610
|
env$1 = { ...env$1 };
|
|
32646
32611
|
const pathName = pathKey({ env: env$1 });
|
|
32647
32612
|
options.path = env$1[pathName];
|
|
@@ -33776,7 +33741,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
|
|
|
33776
33741
|
};
|
|
33777
33742
|
const getDefaultCwd = () => {
|
|
33778
33743
|
try {
|
|
33779
|
-
return
|
|
33744
|
+
return process$1.cwd();
|
|
33780
33745
|
} catch (error) {
|
|
33781
33746
|
error.message = `The current directory does not exist.\n${error.message}`;
|
|
33782
33747
|
throw error;
|
|
@@ -33811,7 +33776,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
|
33811
33776
|
options.killSignal = normalizeKillSignal(options.killSignal);
|
|
33812
33777
|
options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
|
|
33813
33778
|
options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
|
|
33814
|
-
if (
|
|
33779
|
+
if (process$1.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
|
|
33815
33780
|
return {
|
|
33816
33781
|
file,
|
|
33817
33782
|
commandArguments,
|
|
@@ -33838,7 +33803,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
|
|
|
33838
33803
|
});
|
|
33839
33804
|
const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
|
|
33840
33805
|
const env$1 = extendEnv ? {
|
|
33841
|
-
...
|
|
33806
|
+
...process$1.env,
|
|
33842
33807
|
...envOption
|
|
33843
33808
|
} : envOption;
|
|
33844
33809
|
if (preferLocal || node) return npmRunPathEnv({
|
|
@@ -34838,12 +34803,12 @@ const guessStreamDirection = {
|
|
|
34838
34803
|
}
|
|
34839
34804
|
};
|
|
34840
34805
|
const getStandardStreamDirection = (value) => {
|
|
34841
|
-
if ([0,
|
|
34806
|
+
if ([0, process$1.stdin].includes(value)) return "input";
|
|
34842
34807
|
if ([
|
|
34843
34808
|
1,
|
|
34844
34809
|
2,
|
|
34845
|
-
|
|
34846
|
-
|
|
34810
|
+
process$1.stdout,
|
|
34811
|
+
process$1.stderr
|
|
34847
34812
|
].includes(value)) return "output";
|
|
34848
34813
|
};
|
|
34849
34814
|
const DEFAULT_DIRECTION = "output";
|
|
@@ -35907,9 +35872,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
|
|
|
35907
35872
|
Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
|
|
35908
35873
|
};
|
|
35909
35874
|
const getIpcExport = () => {
|
|
35910
|
-
const anyProcess =
|
|
35875
|
+
const anyProcess = process$1;
|
|
35911
35876
|
const isSubprocess = true;
|
|
35912
|
-
const ipc =
|
|
35877
|
+
const ipc = process$1.channel !== void 0;
|
|
35913
35878
|
return {
|
|
35914
35879
|
...getIpcMethods(anyProcess, isSubprocess, ipc),
|
|
35915
35880
|
getCancelSignal: getCancelSignal$1.bind(void 0, {
|
|
@@ -36151,7 +36116,7 @@ if (process.platform === "linux") signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SI
|
|
|
36151
36116
|
|
|
36152
36117
|
//#endregion
|
|
36153
36118
|
//#region node_modules/signal-exit/dist/mjs/index.js
|
|
36154
|
-
const processOk = (process$
|
|
36119
|
+
const processOk = (process$5) => !!process$5 && typeof process$5 === "object" && typeof process$5.removeListener === "function" && typeof process$5.emit === "function" && typeof process$5.reallyExit === "function" && typeof process$5.listeners === "function" && typeof process$5.kill === "function" && typeof process$5.pid === "number" && typeof process$5.on === "function";
|
|
36155
36120
|
const kExitEmitter = Symbol.for("signal-exit emitter");
|
|
36156
36121
|
const global$1 = globalThis;
|
|
36157
36122
|
const ObjectDefineProperty = Object.defineProperty.bind(Object);
|
|
@@ -36219,7 +36184,7 @@ var SignalExitFallback = class extends SignalExitBase {
|
|
|
36219
36184
|
};
|
|
36220
36185
|
var SignalExit = class extends SignalExitBase {
|
|
36221
36186
|
/* c8 ignore start */
|
|
36222
|
-
#hupSig = process$
|
|
36187
|
+
#hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
36223
36188
|
/* c8 ignore stop */
|
|
36224
36189
|
#emitter = new Emitter();
|
|
36225
36190
|
#process;
|
|
@@ -36227,15 +36192,15 @@ var SignalExit = class extends SignalExitBase {
|
|
|
36227
36192
|
#originalProcessReallyExit;
|
|
36228
36193
|
#sigListeners = {};
|
|
36229
36194
|
#loaded = false;
|
|
36230
|
-
constructor(process$
|
|
36195
|
+
constructor(process$5) {
|
|
36231
36196
|
super();
|
|
36232
|
-
this.#process = process$
|
|
36197
|
+
this.#process = process$5;
|
|
36233
36198
|
this.#sigListeners = {};
|
|
36234
36199
|
for (const sig of signals) this.#sigListeners[sig] = () => {
|
|
36235
36200
|
const listeners = this.#process.listeners(sig);
|
|
36236
36201
|
let { count: count$1 } = this.#emitter;
|
|
36237
36202
|
/* c8 ignore start */
|
|
36238
|
-
const p$1 = process$
|
|
36203
|
+
const p$1 = process$5;
|
|
36239
36204
|
if (typeof p$1.__signal_exit_emitter__ === "object" && typeof p$1.__signal_exit_emitter__.count === "number") count$1 += p$1.__signal_exit_emitter__.count;
|
|
36240
36205
|
/* c8 ignore stop */
|
|
36241
36206
|
if (listeners.length === count$1) {
|
|
@@ -36243,11 +36208,11 @@ var SignalExit = class extends SignalExitBase {
|
|
|
36243
36208
|
const ret = this.#emitter.emit("exit", null, sig);
|
|
36244
36209
|
/* c8 ignore start */
|
|
36245
36210
|
const s = sig === "SIGHUP" ? this.#hupSig : sig;
|
|
36246
|
-
if (!ret) process$
|
|
36211
|
+
if (!ret) process$5.kill(process$5.pid, s);
|
|
36247
36212
|
}
|
|
36248
36213
|
};
|
|
36249
|
-
this.#originalProcessReallyExit = process$
|
|
36250
|
-
this.#originalProcessEmit = process$
|
|
36214
|
+
this.#originalProcessReallyExit = process$5.reallyExit;
|
|
36215
|
+
this.#originalProcessEmit = process$5.emit;
|
|
36251
36216
|
}
|
|
36252
36217
|
onExit(cb, opts) {
|
|
36253
36218
|
/* c8 ignore start */
|
|
@@ -36314,8 +36279,8 @@ var SignalExit = class extends SignalExitBase {
|
|
|
36314
36279
|
} else return og.call(this.#process, ev, ...args);
|
|
36315
36280
|
}
|
|
36316
36281
|
};
|
|
36317
|
-
const process$
|
|
36318
|
-
const { onExit, load, unload } = signalExitWrap(processOk(process$
|
|
36282
|
+
const process$2 = globalThis.process;
|
|
36283
|
+
const { onExit, load, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
|
|
36319
36284
|
|
|
36320
36285
|
//#endregion
|
|
36321
36286
|
//#region node_modules/execa/lib/terminate/cleanup.js
|
|
@@ -38066,13 +38031,6 @@ var require_lodash = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
38066
38031
|
//#region src/cli/commands/project/create.ts
|
|
38067
38032
|
var import_lodash = /* @__PURE__ */ __toESM(require_lodash(), 1);
|
|
38068
38033
|
const DEFAULT_TEMPLATE_ID = "backend-only";
|
|
38069
|
-
const SUPPORTED_AGENTS = [{
|
|
38070
|
-
value: "cursor",
|
|
38071
|
-
label: "Cursor"
|
|
38072
|
-
}, {
|
|
38073
|
-
value: "claude-code",
|
|
38074
|
-
label: "Claude Code"
|
|
38075
|
-
}];
|
|
38076
38034
|
async function getTemplateById(templateId) {
|
|
38077
38035
|
const templates = await listTemplates();
|
|
38078
38036
|
const template = templates.find((t) => t.id === templateId);
|
|
@@ -38135,7 +38093,6 @@ async function createInteractive(options) {
|
|
|
38135
38093
|
description: result.description || void 0,
|
|
38136
38094
|
projectPath: result.projectPath,
|
|
38137
38095
|
deploy: options.deploy,
|
|
38138
|
-
skills: options.skills,
|
|
38139
38096
|
isInteractive: true
|
|
38140
38097
|
});
|
|
38141
38098
|
}
|
|
@@ -38146,11 +38103,10 @@ async function createNonInteractive(options) {
|
|
|
38146
38103
|
description: options.description,
|
|
38147
38104
|
projectPath: options.path,
|
|
38148
38105
|
deploy: options.deploy,
|
|
38149
|
-
skills: options.skills,
|
|
38150
38106
|
isInteractive: false
|
|
38151
38107
|
});
|
|
38152
38108
|
}
|
|
38153
|
-
async function executeCreate({ template, name: rawName, description, projectPath, deploy,
|
|
38109
|
+
async function executeCreate({ template, name: rawName, description, projectPath, deploy, isInteractive }) {
|
|
38154
38110
|
const name$1 = rawName.trim();
|
|
38155
38111
|
const resolvedPath = resolve(projectPath);
|
|
38156
38112
|
const { projectId } = await runTask("Setting up your project...", async () => {
|
|
@@ -38210,45 +38166,12 @@ async function executeCreate({ template, name: rawName, description, projectPath
|
|
|
38210
38166
|
finalAppUrl = appUrl;
|
|
38211
38167
|
}
|
|
38212
38168
|
}
|
|
38213
|
-
let selectedAgents = [];
|
|
38214
|
-
if (isInteractive) {
|
|
38215
|
-
const result = await fe({
|
|
38216
|
-
message: "Add AI agent skills? (Select agents to configure)",
|
|
38217
|
-
options: SUPPORTED_AGENTS,
|
|
38218
|
-
initialValues: SUPPORTED_AGENTS.map((agent) => agent.value),
|
|
38219
|
-
required: false
|
|
38220
|
-
});
|
|
38221
|
-
if (!pD(result)) selectedAgents = result;
|
|
38222
|
-
} else if (skills) selectedAgents = SUPPORTED_AGENTS.map((agent) => agent.value);
|
|
38223
|
-
if (selectedAgents.length > 0) {
|
|
38224
|
-
const agentArgs = selectedAgents.flatMap((agent) => ["-a", agent]);
|
|
38225
|
-
M.step(`Installing skills for: ${selectedAgents.join(", ")}`);
|
|
38226
|
-
await runTask(`Installing skills for: ${selectedAgents.join(", ")}`, async () => {
|
|
38227
|
-
await execa("npx", [
|
|
38228
|
-
"-y",
|
|
38229
|
-
"add-skill",
|
|
38230
|
-
"base44/skills",
|
|
38231
|
-
"-y",
|
|
38232
|
-
"-s",
|
|
38233
|
-
"base44-cli",
|
|
38234
|
-
"-s",
|
|
38235
|
-
"base44-sdk",
|
|
38236
|
-
...agentArgs
|
|
38237
|
-
], {
|
|
38238
|
-
cwd: resolvedPath,
|
|
38239
|
-
stdio: "inherit"
|
|
38240
|
-
});
|
|
38241
|
-
}, {
|
|
38242
|
-
successMessage: theme.colors.base44Orange("AI agent skills added successfully"),
|
|
38243
|
-
errorMessage: "Failed to add AI agent skills - you can add them later with: npx add-skill base44/skills"
|
|
38244
|
-
});
|
|
38245
|
-
}
|
|
38246
38169
|
M.message(`${theme.styles.header("Project")}: ${theme.colors.base44Orange(name$1)}`);
|
|
38247
38170
|
M.message(`${theme.styles.header("Dashboard")}: ${theme.colors.links(getDashboardUrl(projectId))}`);
|
|
38248
38171
|
if (finalAppUrl) M.message(`${theme.styles.header("Site")}: ${theme.colors.links(finalAppUrl)}`);
|
|
38249
38172
|
return { outroMessage: "Your project is set up and ready to use" };
|
|
38250
38173
|
}
|
|
38251
|
-
const createCommand = new Command("create").description("Create a new Base44 project").option("-n, --name <name>", "Project name").option("-d, --description <description>", "Project description").option("-p, --path <path>", "Path where to create the project").option("-t, --template <id>", "Template ID (e.g., backend-only, backend-and-client)").option("--deploy", "Build and deploy the site").
|
|
38174
|
+
const createCommand = new Command("create").description("Create a new Base44 project").option("-n, --name <name>", "Project name").option("-d, --description <description>", "Project description").option("-p, --path <path>", "Path where to create the project").option("-t, --template <id>", "Template ID (e.g., backend-only, backend-and-client)").option("--deploy", "Build and deploy the site").hook("preAction", validateNonInteractiveFlags$1).action(async (options) => {
|
|
38252
38175
|
await chooseCreate(options);
|
|
38253
38176
|
});
|
|
38254
38177
|
|
|
@@ -38294,7 +38217,7 @@ function isInsideContainer() {
|
|
|
38294
38217
|
//#endregion
|
|
38295
38218
|
//#region node_modules/is-wsl/index.js
|
|
38296
38219
|
const isWsl = () => {
|
|
38297
|
-
if (
|
|
38220
|
+
if (process$1.platform !== "linux") return false;
|
|
38298
38221
|
if (os.release().toLowerCase().includes("microsoft")) {
|
|
38299
38222
|
if (isInsideContainer()) return false;
|
|
38300
38223
|
return true;
|
|
@@ -38305,12 +38228,12 @@ const isWsl = () => {
|
|
|
38305
38228
|
return false;
|
|
38306
38229
|
}
|
|
38307
38230
|
};
|
|
38308
|
-
var is_wsl_default =
|
|
38231
|
+
var is_wsl_default = process$1.env.__IS_WSL_TEST__ ? isWsl : isWsl();
|
|
38309
38232
|
|
|
38310
38233
|
//#endregion
|
|
38311
38234
|
//#region node_modules/powershell-utils/index.js
|
|
38312
38235
|
const execFile$2 = promisify(childProcess.execFile);
|
|
38313
|
-
const powerShellPath$1 = () => `${
|
|
38236
|
+
const powerShellPath$1 = () => `${process$1.env.SYSTEMROOT || process$1.env.windir || String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;
|
|
38314
38237
|
const executePowerShell = async (command, options = {}) => {
|
|
38315
38238
|
const { powerShellPath: psPath, ...execFileOptions } = options;
|
|
38316
38239
|
const encodedCommand = executePowerShell.encodeCommand(command);
|
|
@@ -38421,7 +38344,7 @@ function defineLazyProperty(object$1, propertyName, valueGetter) {
|
|
|
38421
38344
|
//#region node_modules/default-browser-id/index.js
|
|
38422
38345
|
const execFileAsync$3 = promisify(execFile);
|
|
38423
38346
|
async function defaultBrowserId() {
|
|
38424
|
-
if (
|
|
38347
|
+
if (process$1.platform !== "darwin") throw new Error("macOS only");
|
|
38425
38348
|
const { stdout: stdout$1 } = await execFileAsync$3("defaults", [
|
|
38426
38349
|
"read",
|
|
38427
38350
|
"com.apple.LaunchServices/com.apple.launchservices.secure",
|
|
@@ -38436,7 +38359,7 @@ async function defaultBrowserId() {
|
|
|
38436
38359
|
//#region node_modules/run-applescript/index.js
|
|
38437
38360
|
const execFileAsync$2 = promisify(execFile);
|
|
38438
38361
|
async function runAppleScript(script, { humanReadableOutput = true, signal } = {}) {
|
|
38439
|
-
if (
|
|
38362
|
+
if (process$1.platform !== "darwin") throw new Error("macOS only");
|
|
38440
38363
|
const outputArguments = humanReadableOutput ? [] : ["-ss"];
|
|
38441
38364
|
const execOptions = {};
|
|
38442
38365
|
if (signal) execOptions.signal = signal;
|
|
@@ -38545,14 +38468,14 @@ async function defaultBrowser$1(_execFileAsync = execFileAsync$1) {
|
|
|
38545
38468
|
const execFileAsync = promisify(execFile);
|
|
38546
38469
|
const titleize = (string$2) => string$2.toLowerCase().replaceAll(/(?:^|\s|-)\S/g, (x$2) => x$2.toUpperCase());
|
|
38547
38470
|
async function defaultBrowser() {
|
|
38548
|
-
if (
|
|
38471
|
+
if (process$1.platform === "darwin") {
|
|
38549
38472
|
const id = await defaultBrowserId();
|
|
38550
38473
|
return {
|
|
38551
38474
|
name: await bundleName(id),
|
|
38552
38475
|
id
|
|
38553
38476
|
};
|
|
38554
38477
|
}
|
|
38555
|
-
if (
|
|
38478
|
+
if (process$1.platform === "linux") {
|
|
38556
38479
|
const { stdout: stdout$1 } = await execFileAsync("xdg-mime", [
|
|
38557
38480
|
"query",
|
|
38558
38481
|
"default",
|
|
@@ -38564,13 +38487,13 @@ async function defaultBrowser() {
|
|
|
38564
38487
|
id
|
|
38565
38488
|
};
|
|
38566
38489
|
}
|
|
38567
|
-
if (
|
|
38490
|
+
if (process$1.platform === "win32") return defaultBrowser$1();
|
|
38568
38491
|
throw new Error("Only macOS, Linux, and Windows are supported");
|
|
38569
38492
|
}
|
|
38570
38493
|
|
|
38571
38494
|
//#endregion
|
|
38572
38495
|
//#region node_modules/is-in-ssh/index.js
|
|
38573
|
-
const isInSsh = Boolean(
|
|
38496
|
+
const isInSsh = Boolean(process$1.env.SSH_CONNECTION || process$1.env.SSH_CLIENT || process$1.env.SSH_TTY);
|
|
38574
38497
|
var is_in_ssh_default = isInSsh;
|
|
38575
38498
|
|
|
38576
38499
|
//#endregion
|
|
@@ -38578,7 +38501,7 @@ var is_in_ssh_default = isInSsh;
|
|
|
38578
38501
|
const fallbackAttemptSymbol = Symbol("fallbackAttempt");
|
|
38579
38502
|
const __dirname = import.meta.url ? path.dirname(fileURLToPath(import.meta.url)) : "";
|
|
38580
38503
|
const localXdgOpenPath = path.join(__dirname, "xdg-open");
|
|
38581
|
-
const { platform: platform$1, arch } =
|
|
38504
|
+
const { platform: platform$1, arch } = process$1;
|
|
38582
38505
|
const tryEachApp = async (apps$1, opener) => {
|
|
38583
38506
|
if (apps$1.length === 0) return;
|
|
38584
38507
|
const errors = [];
|
|
@@ -38691,7 +38614,7 @@ const baseOpen = async (options) => {
|
|
|
38691
38614
|
await fs$1.access(localXdgOpenPath, constants$1.X_OK);
|
|
38692
38615
|
exeLocalXdgOpen = true;
|
|
38693
38616
|
} catch {}
|
|
38694
|
-
command =
|
|
38617
|
+
command = process$1.versions.electron ?? (platform$1 === "android" || isBundled || !exeLocalXdgOpen) ? "xdg-open" : localXdgOpenPath;
|
|
38695
38618
|
}
|
|
38696
38619
|
if (appArguments.length > 0) cliArguments.push(...appArguments);
|
|
38697
38620
|
if (!options.wait) {
|
|
@@ -38795,7 +38718,7 @@ var open_default = open;
|
|
|
38795
38718
|
//#region src/cli/commands/project/dashboard.ts
|
|
38796
38719
|
async function openDashboard() {
|
|
38797
38720
|
const dashboardUrl = getDashboardUrl();
|
|
38798
|
-
|
|
38721
|
+
await open_default(dashboardUrl);
|
|
38799
38722
|
return { outroMessage: `Dashboard opened at ${dashboardUrl}` };
|
|
38800
38723
|
}
|
|
38801
38724
|
const dashboardCommand = new Command("dashboard").description("Open the app dashboard in your browser").action(async () => {
|
|
@@ -38977,7 +38900,7 @@ const siteDeployCommand = new Command("site").description("Manage site deploymen
|
|
|
38977
38900
|
var version = "0.0.17";
|
|
38978
38901
|
|
|
38979
38902
|
//#endregion
|
|
38980
|
-
//#region src/cli/
|
|
38903
|
+
//#region src/cli/index.ts
|
|
38981
38904
|
const program = new Command();
|
|
38982
38905
|
program.name("base44").description("Base44 CLI - Unified interface for managing Base44 applications").version(version);
|
|
38983
38906
|
program.configureHelp({ sortSubcommands: true });
|
|
@@ -38991,6 +38914,7 @@ program.addCommand(linkCommand);
|
|
|
38991
38914
|
program.addCommand(entitiesPushCommand);
|
|
38992
38915
|
program.addCommand(functionsDeployCommand);
|
|
38993
38916
|
program.addCommand(siteDeployCommand);
|
|
38917
|
+
program.parse();
|
|
38994
38918
|
|
|
38995
38919
|
//#endregion
|
|
38996
|
-
export {
|
|
38920
|
+
export { };
|
package/package.json
CHANGED
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@base44-preview/cli",
|
|
3
|
-
"version": "0.0.17-pr.
|
|
3
|
+
"version": "0.0.17-pr.93.acb621a",
|
|
4
4
|
"description": "Base44 CLI - Unified interface for managing Base44 applications",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"
|
|
7
|
-
|
|
6
|
+
"main": "./dist/cli/index.js",
|
|
7
|
+
"bin": "./dist/cli/index.js",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": "./dist/cli/index.js"
|
|
8
10
|
},
|
|
9
11
|
"files": [
|
|
10
|
-
"dist"
|
|
11
|
-
"bin"
|
|
12
|
+
"dist"
|
|
12
13
|
],
|
|
13
14
|
"scripts": {
|
|
14
15
|
"build": "tsdown",
|
|
15
16
|
"typecheck": "tsc --noEmit",
|
|
16
|
-
"dev": "
|
|
17
|
-
"start": "
|
|
17
|
+
"dev": "tsx src/cli/index.ts",
|
|
18
|
+
"start": "node dist/cli/index.js",
|
|
18
19
|
"clean": "rm -rf dist",
|
|
19
|
-
"lint": "eslint src
|
|
20
|
+
"lint": "eslint src",
|
|
20
21
|
"test": "vitest run",
|
|
21
22
|
"test:watch": "vitest"
|
|
22
23
|
},
|
|
@@ -52,12 +53,9 @@
|
|
|
52
53
|
"json5": "^2.2.3",
|
|
53
54
|
"ky": "^1.14.2",
|
|
54
55
|
"lodash.kebabcase": "^4.1.1",
|
|
55
|
-
"msw": "^2.12.7",
|
|
56
56
|
"open": "^11.0.0",
|
|
57
57
|
"p-wait-for": "^6.0.0",
|
|
58
|
-
"strip-ansi": "^7.1.2",
|
|
59
58
|
"tar": "^7.5.4",
|
|
60
|
-
"tmp-promise": "^3.0.3",
|
|
61
59
|
"tsdown": "^0.12.4",
|
|
62
60
|
"tsx": "^4.19.2",
|
|
63
61
|
"typescript": "^5.7.2",
|
|
@@ -67,8 +65,5 @@
|
|
|
67
65
|
},
|
|
68
66
|
"engines": {
|
|
69
67
|
"node": ">=20.19.0"
|
|
70
|
-
},
|
|
71
|
-
"optionalDependencies": {
|
|
72
|
-
"@rollup/rollup-linux-x64-gnu": "^4.56.0"
|
|
73
68
|
}
|
|
74
69
|
}
|
package/bin/dev.cmd
DELETED
package/bin/dev.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env tsx
|
|
2
|
-
import { program, CLIExitError } from "../src/cli/index.ts";
|
|
3
|
-
|
|
4
|
-
try {
|
|
5
|
-
await program.parseAsync();
|
|
6
|
-
} catch (error) {
|
|
7
|
-
if (error instanceof CLIExitError) {
|
|
8
|
-
process.exit(error.code);
|
|
9
|
-
}
|
|
10
|
-
console.error(error);
|
|
11
|
-
process.exit(1);
|
|
12
|
-
}
|
package/bin/run.cmd
DELETED
package/bin/run.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import { program, CLIExitError } from "../dist/index.js";
|
|
3
|
-
|
|
4
|
-
try {
|
|
5
|
-
await program.parseAsync();
|
|
6
|
-
} catch (error) {
|
|
7
|
-
if (error instanceof CLIExitError) {
|
|
8
|
-
process.exit(error.code);
|
|
9
|
-
}
|
|
10
|
-
console.error(error);
|
|
11
|
-
process.exit(1);
|
|
12
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|