@base44-preview/cli 0.1.16-pr.634.5f61e77 → 0.1.16-pr.634.6a72fc8
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 +16 -11
- package/dist/cli/index.js.map +6 -6
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -230705,10 +230705,10 @@ var TemplatesConfigSchema = object({
|
|
|
230705
230705
|
templates: array(TemplateSchema)
|
|
230706
230706
|
});
|
|
230707
230707
|
var SiteConfigSchema = object({
|
|
230708
|
-
buildCommand: string2().
|
|
230708
|
+
buildCommand: string2().default("npm run build"),
|
|
230709
230709
|
serveCommand: string2().optional(),
|
|
230710
|
-
outputDirectory: string2().optional()
|
|
230711
|
-
installCommand: string2().
|
|
230710
|
+
outputDirectory: string2().optional(),
|
|
230711
|
+
installCommand: string2().default("npm install")
|
|
230712
230712
|
});
|
|
230713
230713
|
var PluginMetadataSchema = object({
|
|
230714
230714
|
namespace: string2().min(1, "Plugin namespace cannot be empty").regex(/^[a-zA-Z0-9_-]+$/, "Plugin namespace can only contain letters, numbers, underscores, and dashes")
|
|
@@ -246691,7 +246691,7 @@ function hasResourcesToDeploy(projectData) {
|
|
|
246691
246691
|
connectors,
|
|
246692
246692
|
authConfig
|
|
246693
246693
|
} = projectData;
|
|
246694
|
-
const hasSite = project.site
|
|
246694
|
+
const hasSite = Boolean(project.site?.outputDirectory);
|
|
246695
246695
|
const hasEntities = entities.length > 0;
|
|
246696
246696
|
const hasFunctions = functions.length > 0;
|
|
246697
246697
|
const hasActors = actors.length > 0;
|
|
@@ -251020,7 +251020,7 @@ async function deployTarball({ runTask }, project) {
|
|
|
251020
251020
|
throw new ConfigNotFoundError("No site configuration found.", {
|
|
251021
251021
|
hints: [
|
|
251022
251022
|
{
|
|
251023
|
-
message: `Add
|
|
251023
|
+
message: `Add 'site.outputDirectory' to your config.jsonc (e.g., "site": { "outputDirectory": "dist" })`
|
|
251024
251024
|
}
|
|
251025
251025
|
]
|
|
251026
251026
|
});
|
|
@@ -255812,17 +255812,22 @@ async function eject(ctx, options, command) {
|
|
|
255812
255812
|
errorMessage: "Failed to pull project"
|
|
255813
255813
|
});
|
|
255814
255814
|
const { project } = await readProjectConfig(resolvedPath);
|
|
255815
|
-
const
|
|
255816
|
-
|
|
255817
|
-
if (installCommand && buildCommand) {
|
|
255815
|
+
const site = project.site;
|
|
255816
|
+
if (site?.outputDirectory) {
|
|
255818
255817
|
const shouldDeploy = options.yes ? true : await Re({
|
|
255819
255818
|
message: "Would you like to deploy your project now?"
|
|
255820
255819
|
});
|
|
255821
255820
|
if (!Ct(shouldDeploy) && shouldDeploy) {
|
|
255822
255821
|
await runTask("Installing dependencies...", async (updateMessage) => {
|
|
255823
|
-
await execa({
|
|
255822
|
+
await execa({
|
|
255823
|
+
cwd: resolvedPath,
|
|
255824
|
+
shell: true
|
|
255825
|
+
})`${site.installCommand}`;
|
|
255824
255826
|
updateMessage("Building project...");
|
|
255825
|
-
await execa({
|
|
255827
|
+
await execa({
|
|
255828
|
+
cwd: resolvedPath,
|
|
255829
|
+
shell: true
|
|
255830
|
+
})`${site.buildCommand}`;
|
|
255826
255831
|
}, {
|
|
255827
255832
|
successMessage: theme.colors.base44Orange("Project built successfully"),
|
|
255828
255833
|
errorMessage: "Failed to build project"
|
|
@@ -259929,4 +259934,4 @@ export {
|
|
|
259929
259934
|
runCLI
|
|
259930
259935
|
};
|
|
259931
259936
|
|
|
259932
|
-
//# debugId=
|
|
259937
|
+
//# debugId=137964A146E2F1D364756E2164756E21
|