@beechcms/cms 0.4.0-preview.6 → 0.4.0-preview.7
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/bin/cli.mjs +10 -1
- package/bin/create.mjs +4 -2
- package/package.json +2 -2
package/bin/cli.mjs
CHANGED
|
@@ -75,8 +75,17 @@ else if (Array.isArray(mod.default)) out = Object.fromEntries(mod.default.map(s
|
|
|
75
75
|
if (out) process.stdout.write(JSON.stringify(out));
|
|
76
76
|
`.trim(),
|
|
77
77
|
], { encoding: 'utf-8' })
|
|
78
|
+
|
|
78
79
|
if (result.status === 0 && result.stdout) {
|
|
79
|
-
try { return JSON.parse(result.stdout) } catch {
|
|
80
|
+
try { return JSON.parse(result.stdout) } catch (err) {
|
|
81
|
+
console.error(' Failed to parse seeds.ts output:', err)
|
|
82
|
+
}
|
|
83
|
+
} else if (result.status !== 0) {
|
|
84
|
+
console.error(' Error loading seeds.ts:')
|
|
85
|
+
console.error(result.stderr || result.stdout || 'Unknown error')
|
|
86
|
+
if (process.version.slice(1).split('.')[0] < 22) {
|
|
87
|
+
console.warn(' Note: Node.js 22.6+ is required to load .ts files directly. Current version:', process.version)
|
|
88
|
+
}
|
|
80
89
|
}
|
|
81
90
|
}
|
|
82
91
|
|
package/bin/create.mjs
CHANGED
|
@@ -104,12 +104,14 @@ function buildPackageJson(name) {
|
|
|
104
104
|
scripts: {
|
|
105
105
|
dev: 'wrangler dev --port 8789',
|
|
106
106
|
deploy: 'wrangler deploy --minify',
|
|
107
|
+
'seed:load': 'npx beech seed:load',
|
|
108
|
+
'seed:load:local': 'npx beech seed:load --local',
|
|
107
109
|
'db:migrate:local': 'wrangler d1 migrations apply ' + name + '-db --local',
|
|
108
110
|
'db:reset:local': 'node -e "require(\'fs\').rmSync(\'.wrangler/state\',{recursive:true,force:true})" && npm run db:migrate:local',
|
|
109
111
|
},
|
|
110
112
|
dependencies: {
|
|
111
|
-
'@beechcms/api': '^0.4.0-preview.
|
|
112
|
-
'@beechcms/core': '^0.4.0-preview.
|
|
113
|
+
'@beechcms/api': '^0.4.0-preview.6',
|
|
114
|
+
'@beechcms/core': '^0.4.0-preview.6',
|
|
113
115
|
},
|
|
114
116
|
devDependencies: {
|
|
115
117
|
'@cloudflare/workers-types': '^4.0.0',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@beechcms/cms",
|
|
3
|
-
"version": "0.4.0-preview.
|
|
3
|
+
"version": "0.4.0-preview.7",
|
|
4
4
|
"packageManager": "npm@11.9.0",
|
|
5
5
|
"description": "Edge-Native, Schema-Driven Headless CMS built on Cloudflare Workers, D1, and R2. Features the Botanical Engine for alias-stable field management, a modular widget layer, and a React + Vite admin dashboard.",
|
|
6
6
|
"keywords": [
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"typescript": "^5.9.3"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@beechcms/cli": "^0.4.0-preview.
|
|
59
|
+
"@beechcms/cli": "^0.4.0-preview.7",
|
|
60
60
|
"@clack/prompts": "^0.9.1",
|
|
61
61
|
"picocolors": "^1.1.1"
|
|
62
62
|
}
|