riverbankcms 0.2.0 → 0.4.0
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 +14 -0
- package/dist/acceptance/matrix.mjs +119 -6
- package/dist/cli/index.mjs +15262 -4476
- package/dist/cli/init-docs/content/agents-section.md +9 -2
- package/dist/cli/init-docs/content/cli-reference.md +105 -8
- package/dist/cli/init-docs/content/content-management.md +50 -7
- package/dist/cli/init-docs/content/getting-started.md +8 -10
- package/dist/cli/init-docs/content/workflow-add-block.md +8 -1
- package/dist/cli/init-docs/content/workflow-block-extensions.md +25 -9
- package/dist/cli/init-docs/content/workflow-custom-block.md +35 -8
- package/dist/cli/init-docs/content/workflow-preview-mode.md +30 -6
- package/dist/cli/init-docs/content/workflow-remote-setup.md +66 -10
- package/dist/{eventUpsertInputSchema-BUeXa6jk.mjs → eventUpsertInputSchema-Dg60PKJI.mjs} +13 -15
- package/dist/{load-config-CJUwrGHA.mjs → load-config-Co37ncZD.mjs} +1 -1
- package/dist/load-config-Dz8ygC-Z.mjs +5 -0
- package/dist/plan-CaWqAqfn.mjs +2213 -0
- package/dist/scaffold/index.mjs +5 -0
- package/dist/sdk-event-upsert-C6zsxDcf.mjs +887 -0
- package/dist/{sdk-peer-D9FHJ54i.mjs → sdk-peer-DZNUBvf5.mjs} +5 -2
- package/dist/{sdk-event-upsert-CTqsrhFT.mjs → src-BRAF1Dee.mjs} +707 -822
- package/dist/{style-lftMrun_.mjs → style-TmApGKZX.mjs} +32667 -31550
- package/dist/testing.mjs +4 -3
- package/package.json +6 -1
- package/dist/load-config-CcQyVy3r.mjs +0 -5
package/README.md
CHANGED
|
@@ -19,3 +19,17 @@ Safety notes: `--verify-noop` is an applied-write check and cannot be combined
|
|
|
19
19
|
with `--dry-run`. Remote writes in JSON output or a non-interactive terminal
|
|
20
20
|
must include `--yes`; otherwise the CLI refuses before loading or mutating the
|
|
21
21
|
target.
|
|
22
|
+
|
|
23
|
+
## Media conflict behavior
|
|
24
|
+
|
|
25
|
+
Media replacement flags have been removed. `--overwrite-media` and
|
|
26
|
+
`--force-update-asset` are rejected during option parsing. When the same bytes
|
|
27
|
+
or identifier already belong to another asset, keep the existing asset, choose
|
|
28
|
+
a new identifier, or delete and upload the asset again in the dashboard.
|
|
29
|
+
|
|
30
|
+
This is a breaking CLI change and must be included in the next breaking-version
|
|
31
|
+
release. Deploy the identifier backfill migration before deploying application
|
|
32
|
+
code that requires canonical identifiers on every media row. If the migration
|
|
33
|
+
reports unexpected rows in a local, staging, or restored database, assign those
|
|
34
|
+
listed assets canonical, site-unique identifiers and rerun the migration; do not
|
|
35
|
+
bypass its guard.
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import "../
|
|
3
|
-
import
|
|
2
|
+
import "../src-BRAF1Dee.mjs";
|
|
3
|
+
import "../sdk-event-upsert-C6zsxDcf.mjs";
|
|
4
|
+
import { t as eventUpsertInputSchema } from "../eventUpsertInputSchema-Dg60PKJI.mjs";
|
|
4
5
|
|
|
5
6
|
//#region src/acceptance/matrix-builders.ts
|
|
6
7
|
const workflow = (scenario, stepId) => ({
|
|
@@ -55,6 +56,13 @@ const writeFileStep = (id, path, content) => ({
|
|
|
55
56
|
path,
|
|
56
57
|
content: `${JSON.stringify(content, null, 2)}\n`
|
|
57
58
|
});
|
|
59
|
+
const assertJsonFileStep = (id, path, jsonPath, expected) => ({
|
|
60
|
+
kind: "assert_json_file",
|
|
61
|
+
id,
|
|
62
|
+
path,
|
|
63
|
+
jsonPath,
|
|
64
|
+
expected
|
|
65
|
+
});
|
|
58
66
|
const richText = (text) => ({
|
|
59
67
|
type: "doc",
|
|
60
68
|
content: [{
|
|
@@ -139,7 +147,7 @@ const styleScenario = {
|
|
|
139
147
|
capture("current-selection", "currentSelection", "selectionVersion"),
|
|
140
148
|
"--env=local",
|
|
141
149
|
"--json"
|
|
142
|
-
])]
|
|
150
|
+
], { expectedExitCode: 1 })]
|
|
143
151
|
};
|
|
144
152
|
|
|
145
153
|
//#endregion
|
|
@@ -244,6 +252,55 @@ const navigationScenario = {
|
|
|
244
252
|
]
|
|
245
253
|
};
|
|
246
254
|
|
|
255
|
+
//#endregion
|
|
256
|
+
//#region src/acceptance/booking-settings-scenario.ts
|
|
257
|
+
const bookingSettingsScenario = {
|
|
258
|
+
id: "booking-settings-lifecycle",
|
|
259
|
+
steps: [
|
|
260
|
+
commandStep("apply", "settings booking configure", [
|
|
261
|
+
"settings",
|
|
262
|
+
"booking",
|
|
263
|
+
"configure",
|
|
264
|
+
"--vertical",
|
|
265
|
+
"fitness_pt",
|
|
266
|
+
"--preset",
|
|
267
|
+
"fitness_pt.group_training",
|
|
268
|
+
"--env=local",
|
|
269
|
+
"--yes",
|
|
270
|
+
"--json"
|
|
271
|
+
]),
|
|
272
|
+
commandStep("unchanged", "settings booking configure", [
|
|
273
|
+
"settings",
|
|
274
|
+
"booking",
|
|
275
|
+
"configure",
|
|
276
|
+
"--vertical",
|
|
277
|
+
"fitness_pt",
|
|
278
|
+
"--preset",
|
|
279
|
+
"fitness_pt.group_training",
|
|
280
|
+
"--env=local",
|
|
281
|
+
"--yes",
|
|
282
|
+
"--json"
|
|
283
|
+
], { jsonAssertions: [{
|
|
284
|
+
jsonPath: [
|
|
285
|
+
"environments",
|
|
286
|
+
"0",
|
|
287
|
+
"effect",
|
|
288
|
+
"kind"
|
|
289
|
+
],
|
|
290
|
+
expected: "unchanged"
|
|
291
|
+
}] }),
|
|
292
|
+
commandStep("pull-settings", "pull", [
|
|
293
|
+
"pull",
|
|
294
|
+
"settings",
|
|
295
|
+
"--env=local",
|
|
296
|
+
"--yes",
|
|
297
|
+
"--json"
|
|
298
|
+
]),
|
|
299
|
+
assertJsonFileStep("assert-vertical", "content/settings.json", ["verticalConfig", "verticalId"], "fitness_pt"),
|
|
300
|
+
assertJsonFileStep("assert-presets", "content/settings.json", ["verticalConfig", "selectedPresetIds"], ["fitness_pt.group_training"])
|
|
301
|
+
]
|
|
302
|
+
};
|
|
303
|
+
|
|
247
304
|
//#endregion
|
|
248
305
|
//#region src/acceptance/matrix.ts
|
|
249
306
|
const entryScenario = {
|
|
@@ -257,7 +314,7 @@ const entryScenario = {
|
|
|
257
314
|
"--data",
|
|
258
315
|
JSON.stringify({
|
|
259
316
|
excerpt: "Entry created by the installed CLI acceptance workflow.",
|
|
260
|
-
|
|
317
|
+
content: richText("Acceptance entry body.")
|
|
261
318
|
}),
|
|
262
319
|
"--env=local",
|
|
263
320
|
"--json"
|
|
@@ -522,7 +579,7 @@ const eventScenario = {
|
|
|
522
579
|
const acceptanceTuples = [
|
|
523
580
|
["push-config", scratchDryRun([
|
|
524
581
|
"push-config",
|
|
525
|
-
"--env=
|
|
582
|
+
"--env=local",
|
|
526
583
|
"--dry-run",
|
|
527
584
|
"--json"
|
|
528
585
|
])],
|
|
@@ -539,7 +596,7 @@ const acceptanceTuples = [
|
|
|
539
596
|
["push", scratchDryRun([
|
|
540
597
|
"push",
|
|
541
598
|
"pages",
|
|
542
|
-
"--env=
|
|
599
|
+
"--env=local",
|
|
543
600
|
"--dry-run",
|
|
544
601
|
"--json"
|
|
545
602
|
])],
|
|
@@ -609,6 +666,7 @@ const acceptanceTuples = [
|
|
|
609
666
|
cwd: "nested",
|
|
610
667
|
output: "non-empty"
|
|
611
668
|
})],
|
|
669
|
+
["init", scratchExecute(["init", "--json"], { expectedExitCode: 1 })],
|
|
612
670
|
["identifiers backfill", scratchExecute([
|
|
613
671
|
"identifiers",
|
|
614
672
|
"backfill",
|
|
@@ -690,6 +748,61 @@ const acceptanceTuples = [
|
|
|
690
748
|
"--env=both",
|
|
691
749
|
"--json"
|
|
692
750
|
])],
|
|
751
|
+
["settings booking configure", workflow(bookingSettingsScenario, "apply")],
|
|
752
|
+
["login", scratchExecute([
|
|
753
|
+
"login",
|
|
754
|
+
"--account-env=local",
|
|
755
|
+
"--json"
|
|
756
|
+
], { expectedExitCode: 1 })],
|
|
757
|
+
["logout", scratchExecute([
|
|
758
|
+
"logout",
|
|
759
|
+
"--account-env=local",
|
|
760
|
+
"--json"
|
|
761
|
+
], { expectedExitCode: 1 })],
|
|
762
|
+
["whoami", scratchExecute([
|
|
763
|
+
"whoami",
|
|
764
|
+
"--account-env=local",
|
|
765
|
+
"--json"
|
|
766
|
+
], { expectedExitCode: 1 })],
|
|
767
|
+
["auth revoke", scratchExecute([
|
|
768
|
+
"auth",
|
|
769
|
+
"revoke",
|
|
770
|
+
"--account-env=local",
|
|
771
|
+
"--yes",
|
|
772
|
+
"--json"
|
|
773
|
+
], { expectedExitCode: 1 })],
|
|
774
|
+
["sites list", scratchExecute([
|
|
775
|
+
"sites",
|
|
776
|
+
"list",
|
|
777
|
+
"--account-env=local",
|
|
778
|
+
"--json"
|
|
779
|
+
], { expectedExitCode: 1 })],
|
|
780
|
+
["sites create", scratchExecute([
|
|
781
|
+
"sites",
|
|
782
|
+
"create",
|
|
783
|
+
"--account-env=local",
|
|
784
|
+
"--name",
|
|
785
|
+
"Acceptance site",
|
|
786
|
+
"--yes",
|
|
787
|
+
"--json"
|
|
788
|
+
], { expectedExitCode: 1 })],
|
|
789
|
+
["link", scratchExecute([
|
|
790
|
+
"link",
|
|
791
|
+
"--project",
|
|
792
|
+
".",
|
|
793
|
+
"--site",
|
|
794
|
+
"550e8400-e29b-41d4-a716-446655440000",
|
|
795
|
+
"--no-preview",
|
|
796
|
+
"--account-env=local",
|
|
797
|
+
"--json"
|
|
798
|
+
], { expectedExitCode: 1 })],
|
|
799
|
+
["recover", scratchExecute([
|
|
800
|
+
"recover",
|
|
801
|
+
"--project",
|
|
802
|
+
".",
|
|
803
|
+
"--account-env=local",
|
|
804
|
+
"--json"
|
|
805
|
+
], { expectedExitCode: 1 })],
|
|
693
806
|
["migrate entries", scratchDryRun([
|
|
694
807
|
"migrate",
|
|
695
808
|
"entries",
|