create-kide-app 0.1.9 → 0.1.10
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/index.js +5 -15
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -5,7 +5,6 @@ import { execFileSync, execSync, spawn } from "node:child_process";
|
|
|
5
5
|
import {
|
|
6
6
|
cpSync,
|
|
7
7
|
existsSync,
|
|
8
|
-
mkdirSync,
|
|
9
8
|
readFileSync,
|
|
10
9
|
rmSync,
|
|
11
10
|
writeFileSync,
|
|
@@ -480,22 +479,13 @@ async function main() {
|
|
|
480
479
|
|
|
481
480
|
if (seedDemo && target === "local") {
|
|
482
481
|
s.start("Pushing schema to database");
|
|
483
|
-
//
|
|
484
|
-
|
|
485
|
-
let pushOk = false;
|
|
482
|
+
// The guarded sync script (exits non-zero on failure, creates data/ itself) —
|
|
483
|
+
// same path the dev server and deploys use.
|
|
486
484
|
try {
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
stdio: "pipe",
|
|
490
|
-
}).toString();
|
|
491
|
-
pushOk = !out.includes("Error:") && out.includes("Changes applied");
|
|
492
|
-
s.stop(
|
|
493
|
-
pushOk
|
|
494
|
-
? "Schema pushed"
|
|
495
|
-
: "Schema push failed — run `pnpm exec drizzle-kit push` manually",
|
|
496
|
-
);
|
|
485
|
+
execSync(`${pm.run} cms:push`, { cwd: projectDir, stdio: "pipe" });
|
|
486
|
+
s.stop("Schema pushed");
|
|
497
487
|
} catch {
|
|
498
|
-
s.stop("Schema
|
|
488
|
+
s.stop("Schema push failed — run `pnpm cms:push` manually");
|
|
499
489
|
}
|
|
500
490
|
s.start("Seeding demo content");
|
|
501
491
|
try {
|