@base44-preview/cli 0.1.22-pr.644.9e3658d → 0.1.23-pr.645.b52be01
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.
|
@@ -42,7 +42,9 @@ if (!appBaseUrl) {
|
|
|
42
42
|
Deno.exit(1);
|
|
43
43
|
}
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
// Exact version: an unversioned specifier makes Deno resolve "latest" from npm on
|
|
46
|
+
// every fresh cache, so a pre-cached SDK is never used.
|
|
47
|
+
import { createClient } from "npm:@base44/sdk@0.8.48";
|
|
46
48
|
|
|
47
49
|
const customHeaders: Record<string, string> = {};
|
|
48
50
|
if (isPrivileged) customHeaders["X-Bypass-RLS"] = "true";
|
package/dist/cli/index.js
CHANGED
|
@@ -239265,7 +239265,7 @@ import { join as join13 } from "node:path";
|
|
|
239265
239265
|
// package.json
|
|
239266
239266
|
var package_default = {
|
|
239267
239267
|
name: "base44",
|
|
239268
|
-
version: "0.1.
|
|
239268
|
+
version: "0.1.23",
|
|
239269
239269
|
description: "Base44 CLI - Unified interface for managing Base44 applications",
|
|
239270
239270
|
type: "module",
|
|
239271
239271
|
bin: {
|
|
@@ -247411,8 +247411,7 @@ class Base44Command extends Command2 {
|
|
|
247411
247411
|
if (branch !== undefined && !branch.trim()) {
|
|
247412
247412
|
throw new InvalidInputError("--branch must not be empty.");
|
|
247413
247413
|
}
|
|
247414
|
-
|
|
247415
|
-
if (typeof requireAuth === "function" ? requireAuth() : requireAuth) {
|
|
247414
|
+
if (this._commandOptions.requireAuth) {
|
|
247416
247415
|
await ensureAuth(this.context);
|
|
247417
247416
|
}
|
|
247418
247417
|
if (this._commandOptions.requireAppContext) {
|
|
@@ -256173,8 +256172,8 @@ var EXEC_ENV_VARS = [
|
|
|
256173
256172
|
SERVER_URL_VAR,
|
|
256174
256173
|
SERVICE_TOKEN_VAR
|
|
256175
256174
|
];
|
|
256176
|
-
var PRIVILEGED_ENV_VAR = "
|
|
256177
|
-
var DATA_ENV_ENV_VAR = "
|
|
256175
|
+
var PRIVILEGED_ENV_VAR = "BASE44_PRIVILEGED";
|
|
256176
|
+
var DATA_ENV_ENV_VAR = "BASE44_DATA_ENV";
|
|
256178
256177
|
function read3(env, name) {
|
|
256179
256178
|
return env[name]?.trim() || undefined;
|
|
256180
256179
|
}
|
|
@@ -256325,7 +256324,7 @@ async function execAction({ app, isNonInteractive }, options) {
|
|
|
256325
256324
|
return {};
|
|
256326
256325
|
}
|
|
256327
256326
|
function getExecCommand() {
|
|
256328
|
-
return new Base44Command("exec", { requireAuth:
|
|
256327
|
+
return new Base44Command("exec", { requireAuth: !hasExecEnvTarget() }).description("Run a script with the Base44 SDK pre-authenticated as the current user").option("--local", "Run against the local `base44 dev` server instead of the deployed app").option("--port <number>", `Port the local dev server is on (with --local; defaults to ${DEFAULT_DEV_SERVER_PORT})`).addOption(new Option2("--privileged", "Run with admin privileges (bypass RLS). Requires app owner/editor role.").env(PRIVILEGED_ENV_VAR)).addOption(new Option2("--data-env <environment>", "Data environment to run against (e.g. dev, prod)").env(DATA_ENV_ENV_VAR)).addHelpText("after", `
|
|
256329
256328
|
Examples:
|
|
256330
256329
|
Run a script file:
|
|
256331
256330
|
$ cat ./script.ts | base44 exec
|
|
@@ -256337,15 +256336,7 @@ Examples:
|
|
|
256337
256336
|
$ echo "await base44.entities.Task.create({ title: 'seed' })" | base44 exec --local
|
|
256338
256337
|
|
|
256339
256338
|
With privileged access (bypass RLS):
|
|
256340
|
-
$ echo "const all = await base44.entities.Task.list()" | base44 exec --privileged
|
|
256341
|
-
|
|
256342
|
-
Environment (for sandboxes and agents; no login or linked project needed):
|
|
256343
|
-
BASE44_EXEC_ACCESS_TOKEN App-user token for the SDK (requires BASE44_EXEC_SERVER_URL)
|
|
256344
|
-
BASE44_EXEC_SERVER_URL SDK server URL (requires BASE44_EXEC_ACCESS_TOKEN)
|
|
256345
|
-
BASE44_EXEC_SERVICE_TOKEN Optional service token, enables base44.asServiceRole
|
|
256346
|
-
BASE44_EXEC_PRIVILEGED Same as --privileged (set to any value to enable)
|
|
256347
|
-
BASE44_EXEC_DATA_ENV Same as --data-env
|
|
256348
|
-
The app id comes from --app-id or BASE44_APP_ID.`).action(execAction);
|
|
256339
|
+
$ echo "const all = await base44.entities.Task.list()" | base44 exec --privileged`).action(execAction);
|
|
256349
256340
|
}
|
|
256350
256341
|
|
|
256351
256342
|
// src/cli/commands/project/eject.ts
|
|
@@ -260557,4 +260548,4 @@ export {
|
|
|
260557
260548
|
runCLI
|
|
260558
260549
|
};
|
|
260559
260550
|
|
|
260560
|
-
//# debugId=
|
|
260551
|
+
//# debugId=F91265C83F23C30764756E2164756E21
|