@stardeck-customer-apps/compose 0.14.1 → 0.16.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/SKILL.md +16 -0
- package/dist/cli.js +721 -417
- package/dist/index.js +189 -155
- package/dist/index.mjs +189 -155
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1149,16 +1149,16 @@ var require_range = __commonJS({
|
|
|
1149
1149
|
};
|
|
1150
1150
|
var replaceTilde = (comp, options) => {
|
|
1151
1151
|
const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE];
|
|
1152
|
-
const
|
|
1152
|
+
const z11 = options.includePrerelease ? "-0" : "";
|
|
1153
1153
|
return comp.replace(r, (_, M, m, p, pr) => {
|
|
1154
1154
|
debug("tilde", comp, _, M, m, p, pr);
|
|
1155
1155
|
let ret;
|
|
1156
1156
|
if (isX(M)) {
|
|
1157
1157
|
ret = "";
|
|
1158
1158
|
} else if (isX(m)) {
|
|
1159
|
-
ret = `>=${M}.0.0${
|
|
1159
|
+
ret = `>=${M}.0.0${z11} <${+M + 1}.0.0-0`;
|
|
1160
1160
|
} else if (isX(p)) {
|
|
1161
|
-
ret = `>=${M}.${m}.0${
|
|
1161
|
+
ret = `>=${M}.${m}.0${z11} <${M}.${+m + 1}.0-0`;
|
|
1162
1162
|
} else if (pr) {
|
|
1163
1163
|
debug("replaceTilde pr", pr);
|
|
1164
1164
|
ret = `>=${M}.${m}.${p}-${pr} <${M}.${+m + 1}.0-0`;
|
|
@@ -1175,19 +1175,19 @@ var require_range = __commonJS({
|
|
|
1175
1175
|
var replaceCaret = (comp, options) => {
|
|
1176
1176
|
debug("caret", comp, options);
|
|
1177
1177
|
const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET];
|
|
1178
|
-
const
|
|
1178
|
+
const z11 = options.includePrerelease ? "-0" : "";
|
|
1179
1179
|
return comp.replace(r, (_, M, m, p, pr) => {
|
|
1180
1180
|
debug("caret", comp, _, M, m, p, pr);
|
|
1181
1181
|
let ret;
|
|
1182
1182
|
if (isX(M)) {
|
|
1183
1183
|
ret = "";
|
|
1184
1184
|
} else if (isX(m)) {
|
|
1185
|
-
ret = `>=${M}.0.0${
|
|
1185
|
+
ret = `>=${M}.0.0${z11} <${+M + 1}.0.0-0`;
|
|
1186
1186
|
} else if (isX(p)) {
|
|
1187
1187
|
if (M === "0") {
|
|
1188
|
-
ret = `>=${M}.${m}.0${
|
|
1188
|
+
ret = `>=${M}.${m}.0${z11} <${M}.${+m + 1}.0-0`;
|
|
1189
1189
|
} else {
|
|
1190
|
-
ret = `>=${M}.${m}.0${
|
|
1190
|
+
ret = `>=${M}.${m}.0${z11} <${+M + 1}.0.0-0`;
|
|
1191
1191
|
}
|
|
1192
1192
|
} else if (pr) {
|
|
1193
1193
|
debug("replaceCaret pr", pr);
|
|
@@ -2396,7 +2396,18 @@ var modulePermissionClaimSchema = import_zod2.z.object({
|
|
|
2396
2396
|
* External Viewer never holds one. An organization that wants different access duplicates the
|
|
2397
2397
|
* standard role and edits the copy.
|
|
2398
2398
|
*/
|
|
2399
|
-
roles: import_zod2.z.array(import_zod2.z.enum(MODULE_PERMISSION_DEFAULT_ROLES)).optional()
|
|
2399
|
+
roles: import_zod2.z.array(import_zod2.z.enum(MODULE_PERMISSION_DEFAULT_ROLES)).optional(),
|
|
2400
|
+
/**
|
|
2401
|
+
* Keys this one takes over (a retired or renamed key). On the update that stops declaring
|
|
2402
|
+
* them, every custom role still holding one is granted this key before the old one goes,
|
|
2403
|
+
* so nobody loses access in the change. Standard roles follow `roles` as always.
|
|
2404
|
+
*/
|
|
2405
|
+
replaces: import_zod2.z.array(
|
|
2406
|
+
import_zod2.z.string().regex(
|
|
2407
|
+
/^[a-z0-9][a-z0-9-]*:[a-z0-9][a-z0-9-]*$/,
|
|
2408
|
+
"must be a lowercase resource:action key"
|
|
2409
|
+
)
|
|
2410
|
+
).max(20).optional()
|
|
2400
2411
|
}).strict();
|
|
2401
2412
|
var seedBundleSchema = import_zod2.z.object({
|
|
2402
2413
|
table: tableNameSchema,
|
|
@@ -4036,6 +4047,24 @@ function analyzeClientSafeEntryImports(sourceText, fileName) {
|
|
|
4036
4047
|
return analyzeClientSafeEntryImportsWithTs(import_typescript3.default, sourceText, fileName);
|
|
4037
4048
|
}
|
|
4038
4049
|
|
|
4050
|
+
// ../../packages/lib/src/shared/ownership-record.ts
|
|
4051
|
+
var import_zod7 = require("zod");
|
|
4052
|
+
var OWNERSHIP_RECORD_VERSION = 1;
|
|
4053
|
+
var moduleList = import_zod7.z.array(import_zod7.z.string().refine(isValidModuleName, "not a Module name"));
|
|
4054
|
+
var ownershipRecordSchema = import_zod7.z.object({
|
|
4055
|
+
version: import_zod7.z.literal(OWNERSHIP_RECORD_VERSION),
|
|
4056
|
+
/** False once the app stopped all Stardeck updates: then every file is the app's. */
|
|
4057
|
+
stardeckUpdates: import_zod7.z.boolean(),
|
|
4058
|
+
/** projects.ejected_modules: updates stopped for these Modules, so their folders are the app's. */
|
|
4059
|
+
updatesStoppedModules: moduleList,
|
|
4060
|
+
/** projects.ui_ejected_modules: Customize UI, so their screens are the app's. */
|
|
4061
|
+
customizedUiModules: moduleList,
|
|
4062
|
+
/** projects.external_modules: installed from another app, so the app owns the copy. */
|
|
4063
|
+
externalModules: moduleList,
|
|
4064
|
+
/** projects.removed_modules names: uninstalled on purpose. */
|
|
4065
|
+
uninstalledModules: moduleList
|
|
4066
|
+
});
|
|
4067
|
+
|
|
4039
4068
|
// ../../packages/lib/src/shared/platform-owned-paths.ts
|
|
4040
4069
|
var APP_WEB_PREFIX = "apps/web/";
|
|
4041
4070
|
var BLUEPRINT_LINT_MARKER = `${APP_WEB_PREFIX}eslint-rules/module-boundaries.mjs`;
|
|
@@ -5990,14 +6019,14 @@ function rejectPseudoModuleEntries(entries, parentDir, label) {
|
|
|
5990
6019
|
}
|
|
5991
6020
|
|
|
5992
6021
|
// ../../packages/lib/src/shared/module-composition.ts
|
|
5993
|
-
var
|
|
5994
|
-
var creationSourceBlankSchema =
|
|
5995
|
-
type:
|
|
6022
|
+
var import_zod8 = require("zod");
|
|
6023
|
+
var creationSourceBlankSchema = import_zod8.z.object({
|
|
6024
|
+
type: import_zod8.z.literal("blank")
|
|
5996
6025
|
});
|
|
5997
|
-
var creationSourceBlueprintSchema =
|
|
5998
|
-
type:
|
|
6026
|
+
var creationSourceBlueprintSchema = import_zod8.z.object({
|
|
6027
|
+
type: import_zod8.z.literal("blueprint"),
|
|
5999
6028
|
/** Internal template/fork project id — keep template naming in identifiers. */
|
|
6000
|
-
blueprintProjectId:
|
|
6029
|
+
blueprintProjectId: import_zod8.z.string().uuid(),
|
|
6001
6030
|
/**
|
|
6002
6031
|
* `null`/absent means every feature Module: the platform stores that as the
|
|
6003
6032
|
* explicit list of feature Modules in the published Blueprint version the fork
|
|
@@ -6005,192 +6034,197 @@ var creationSourceBlueprintSchema = import_zod7.z.object({
|
|
|
6005
6034
|
* a custom app: no feature Module, Library Modules only (`resolvePlatformEnv`
|
|
6006
6035
|
* emits it as a set value naming no Module).
|
|
6007
6036
|
*/
|
|
6008
|
-
enabledModules:
|
|
6037
|
+
enabledModules: import_zod8.z.array(moduleNameSchema).max(100).nullable().optional(),
|
|
6038
|
+
/**
|
|
6039
|
+
* The kind of business (a preset id the published version defines). Its Modules are built
|
|
6040
|
+
* and `enabledModules` adds extras on top; for the general kind `enabledModules` is the pick.
|
|
6041
|
+
*/
|
|
6042
|
+
businessKind: import_zod8.z.string().regex(/^[a-z][a-z0-9-]{0,39}$/).optional()
|
|
6009
6043
|
});
|
|
6010
|
-
var creationSourceSchema =
|
|
6044
|
+
var creationSourceSchema = import_zod8.z.discriminatedUnion("type", [
|
|
6011
6045
|
creationSourceBlankSchema,
|
|
6012
6046
|
creationSourceBlueprintSchema
|
|
6013
6047
|
]);
|
|
6014
|
-
var moduleInstallHandoffSchema =
|
|
6015
|
-
moduleName:
|
|
6016
|
-
homeProjectId:
|
|
6017
|
-
installedVersion:
|
|
6018
|
-
baselineSha:
|
|
6019
|
-
mounts:
|
|
6020
|
-
|
|
6021
|
-
group:
|
|
6022
|
-
segment:
|
|
6048
|
+
var moduleInstallHandoffSchema = import_zod8.z.object({
|
|
6049
|
+
moduleName: import_zod8.z.string().min(1),
|
|
6050
|
+
homeProjectId: import_zod8.z.string().uuid(),
|
|
6051
|
+
installedVersion: import_zod8.z.string().min(1),
|
|
6052
|
+
baselineSha: import_zod8.z.string().min(1),
|
|
6053
|
+
mounts: import_zod8.z.array(
|
|
6054
|
+
import_zod8.z.object({
|
|
6055
|
+
group: import_zod8.z.string(),
|
|
6056
|
+
segment: import_zod8.z.string()
|
|
6023
6057
|
})
|
|
6024
6058
|
),
|
|
6025
|
-
integration:
|
|
6026
|
-
workflows:
|
|
6027
|
-
prunedEnhancements:
|
|
6028
|
-
restoredEnhancements:
|
|
6029
|
-
permissions:
|
|
6030
|
-
|
|
6031
|
-
key:
|
|
6032
|
-
description:
|
|
6059
|
+
integration: import_zod8.z.array(import_zod8.z.string()),
|
|
6060
|
+
workflows: import_zod8.z.array(import_zod8.z.string()),
|
|
6061
|
+
prunedEnhancements: import_zod8.z.array(import_zod8.z.string()),
|
|
6062
|
+
restoredEnhancements: import_zod8.z.array(import_zod8.z.string()).optional(),
|
|
6063
|
+
permissions: import_zod8.z.array(
|
|
6064
|
+
import_zod8.z.object({
|
|
6065
|
+
key: import_zod8.z.string().min(1),
|
|
6066
|
+
description: import_zod8.z.string().min(1)
|
|
6033
6067
|
})
|
|
6034
6068
|
).optional()
|
|
6035
6069
|
});
|
|
6036
6070
|
|
|
6037
6071
|
// ../../packages/lib/src/shared/schema-ops.ts
|
|
6038
|
-
var
|
|
6039
|
-
var columnSpecSchema =
|
|
6040
|
-
name:
|
|
6041
|
-
pgType:
|
|
6042
|
-
nullable:
|
|
6072
|
+
var import_zod9 = require("zod");
|
|
6073
|
+
var columnSpecSchema = import_zod9.z.object({
|
|
6074
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6075
|
+
pgType: import_zod9.z.string().min(1),
|
|
6076
|
+
nullable: import_zod9.z.boolean(),
|
|
6043
6077
|
/**
|
|
6044
6078
|
* A SQL expression used as the column default, as a raw string (e.g. `'t'`,
|
|
6045
6079
|
* `0`, `now()`, `gen_random_uuid()`). `null` or omitted means no default.
|
|
6046
6080
|
* NOT a JS literal — must already be a valid SQL expression.
|
|
6047
6081
|
*/
|
|
6048
|
-
default:
|
|
6049
|
-
fieldType:
|
|
6050
|
-
fieldConfig:
|
|
6082
|
+
default: import_zod9.z.string().nullable().optional(),
|
|
6083
|
+
fieldType: import_zod9.z.string().optional(),
|
|
6084
|
+
fieldConfig: import_zod9.z.record(import_zod9.z.string(), import_zod9.z.unknown()).optional()
|
|
6051
6085
|
});
|
|
6052
|
-
var referentialActionSchema =
|
|
6086
|
+
var referentialActionSchema = import_zod9.z.enum([
|
|
6053
6087
|
"cascade",
|
|
6054
6088
|
"set null",
|
|
6055
6089
|
"set default",
|
|
6056
6090
|
"restrict",
|
|
6057
6091
|
"no action"
|
|
6058
6092
|
]);
|
|
6059
|
-
var schemaOpSchema =
|
|
6093
|
+
var schemaOpSchema = import_zod9.z.discriminatedUnion("type", [
|
|
6060
6094
|
// Tables
|
|
6061
|
-
|
|
6062
|
-
type:
|
|
6063
|
-
table:
|
|
6064
|
-
columns:
|
|
6065
|
-
primaryKey:
|
|
6066
|
-
ifNotExists:
|
|
6095
|
+
import_zod9.z.object({
|
|
6096
|
+
type: import_zod9.z.literal("createTable"),
|
|
6097
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6098
|
+
columns: import_zod9.z.array(columnSpecSchema).min(1),
|
|
6099
|
+
primaryKey: import_zod9.z.array(import_zod9.z.string()).optional(),
|
|
6100
|
+
ifNotExists: import_zod9.z.boolean().optional()
|
|
6067
6101
|
}),
|
|
6068
|
-
|
|
6069
|
-
type:
|
|
6070
|
-
table:
|
|
6071
|
-
cascade:
|
|
6072
|
-
ifExists:
|
|
6102
|
+
import_zod9.z.object({
|
|
6103
|
+
type: import_zod9.z.literal("dropTable"),
|
|
6104
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6105
|
+
cascade: import_zod9.z.boolean().optional(),
|
|
6106
|
+
ifExists: import_zod9.z.boolean().optional()
|
|
6073
6107
|
}),
|
|
6074
|
-
|
|
6075
|
-
type:
|
|
6076
|
-
from:
|
|
6077
|
-
to:
|
|
6108
|
+
import_zod9.z.object({
|
|
6109
|
+
type: import_zod9.z.literal("renameTable"),
|
|
6110
|
+
from: import_zod9.z.string().min(1).max(63),
|
|
6111
|
+
to: import_zod9.z.string().min(1).max(63)
|
|
6078
6112
|
}),
|
|
6079
6113
|
// Columns
|
|
6080
|
-
|
|
6081
|
-
type:
|
|
6082
|
-
table:
|
|
6114
|
+
import_zod9.z.object({
|
|
6115
|
+
type: import_zod9.z.literal("addColumn"),
|
|
6116
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6083
6117
|
column: columnSpecSchema,
|
|
6084
|
-
ifNotExists:
|
|
6118
|
+
ifNotExists: import_zod9.z.boolean().optional()
|
|
6085
6119
|
}),
|
|
6086
|
-
|
|
6087
|
-
type:
|
|
6088
|
-
table:
|
|
6089
|
-
column:
|
|
6090
|
-
cascade:
|
|
6091
|
-
ifExists:
|
|
6120
|
+
import_zod9.z.object({
|
|
6121
|
+
type: import_zod9.z.literal("dropColumn"),
|
|
6122
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6123
|
+
column: import_zod9.z.string().min(1).max(63),
|
|
6124
|
+
cascade: import_zod9.z.boolean().optional(),
|
|
6125
|
+
ifExists: import_zod9.z.boolean().optional()
|
|
6092
6126
|
}),
|
|
6093
|
-
|
|
6094
|
-
type:
|
|
6095
|
-
table:
|
|
6096
|
-
from:
|
|
6097
|
-
to:
|
|
6127
|
+
import_zod9.z.object({
|
|
6128
|
+
type: import_zod9.z.literal("renameColumn"),
|
|
6129
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6130
|
+
from: import_zod9.z.string().min(1).max(63),
|
|
6131
|
+
to: import_zod9.z.string().min(1).max(63)
|
|
6098
6132
|
}),
|
|
6099
|
-
|
|
6100
|
-
type:
|
|
6101
|
-
table:
|
|
6102
|
-
column:
|
|
6103
|
-
newType:
|
|
6133
|
+
import_zod9.z.object({
|
|
6134
|
+
type: import_zod9.z.literal("alterColumnType"),
|
|
6135
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6136
|
+
column: import_zod9.z.string().min(1).max(63),
|
|
6137
|
+
newType: import_zod9.z.string().min(1),
|
|
6104
6138
|
/** Optional USING expression for potentially-lossy casts */
|
|
6105
|
-
using:
|
|
6139
|
+
using: import_zod9.z.string().optional()
|
|
6106
6140
|
}),
|
|
6107
|
-
|
|
6108
|
-
type:
|
|
6109
|
-
table:
|
|
6110
|
-
column:
|
|
6111
|
-
nullable:
|
|
6141
|
+
import_zod9.z.object({
|
|
6142
|
+
type: import_zod9.z.literal("alterColumnNullable"),
|
|
6143
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6144
|
+
column: import_zod9.z.string().min(1).max(63),
|
|
6145
|
+
nullable: import_zod9.z.boolean()
|
|
6112
6146
|
}),
|
|
6113
|
-
|
|
6114
|
-
type:
|
|
6115
|
-
table:
|
|
6116
|
-
column:
|
|
6147
|
+
import_zod9.z.object({
|
|
6148
|
+
type: import_zod9.z.literal("alterColumnDefault"),
|
|
6149
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6150
|
+
column: import_zod9.z.string().min(1).max(63),
|
|
6117
6151
|
/** null means drop the default; otherwise a SQL expression string. */
|
|
6118
|
-
default:
|
|
6152
|
+
default: import_zod9.z.string().nullable()
|
|
6119
6153
|
}),
|
|
6120
6154
|
// Indexes
|
|
6121
|
-
|
|
6122
|
-
type:
|
|
6123
|
-
table:
|
|
6124
|
-
name:
|
|
6125
|
-
columns:
|
|
6126
|
-
unique:
|
|
6155
|
+
import_zod9.z.object({
|
|
6156
|
+
type: import_zod9.z.literal("addIndex"),
|
|
6157
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6158
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6159
|
+
columns: import_zod9.z.array(import_zod9.z.string().min(1)).min(1),
|
|
6160
|
+
unique: import_zod9.z.boolean().optional(),
|
|
6127
6161
|
/** Partial-index WHERE clause, as a raw SQL expression */
|
|
6128
|
-
where:
|
|
6129
|
-
ifNotExists:
|
|
6162
|
+
where: import_zod9.z.string().optional(),
|
|
6163
|
+
ifNotExists: import_zod9.z.boolean().optional()
|
|
6130
6164
|
}),
|
|
6131
|
-
|
|
6132
|
-
type:
|
|
6133
|
-
name:
|
|
6134
|
-
cascade:
|
|
6135
|
-
ifExists:
|
|
6165
|
+
import_zod9.z.object({
|
|
6166
|
+
type: import_zod9.z.literal("dropIndex"),
|
|
6167
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6168
|
+
cascade: import_zod9.z.boolean().optional(),
|
|
6169
|
+
ifExists: import_zod9.z.boolean().optional()
|
|
6136
6170
|
}),
|
|
6137
6171
|
// Constraints
|
|
6138
|
-
|
|
6139
|
-
type:
|
|
6140
|
-
table:
|
|
6141
|
-
name:
|
|
6142
|
-
columns:
|
|
6143
|
-
refTable:
|
|
6144
|
-
refColumns:
|
|
6172
|
+
import_zod9.z.object({
|
|
6173
|
+
type: import_zod9.z.literal("addForeignKey"),
|
|
6174
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6175
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6176
|
+
columns: import_zod9.z.array(import_zod9.z.string().min(1)).min(1),
|
|
6177
|
+
refTable: import_zod9.z.string().min(1).max(63),
|
|
6178
|
+
refColumns: import_zod9.z.array(import_zod9.z.string().min(1)).min(1),
|
|
6145
6179
|
onDelete: referentialActionSchema.optional(),
|
|
6146
6180
|
onUpdate: referentialActionSchema.optional()
|
|
6147
6181
|
}),
|
|
6148
|
-
|
|
6149
|
-
type:
|
|
6150
|
-
table:
|
|
6151
|
-
name:
|
|
6152
|
-
columns:
|
|
6182
|
+
import_zod9.z.object({
|
|
6183
|
+
type: import_zod9.z.literal("addUniqueConstraint"),
|
|
6184
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6185
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6186
|
+
columns: import_zod9.z.array(import_zod9.z.string().min(1)).min(1)
|
|
6153
6187
|
}),
|
|
6154
|
-
|
|
6155
|
-
type:
|
|
6156
|
-
table:
|
|
6157
|
-
name:
|
|
6158
|
-
expression:
|
|
6188
|
+
import_zod9.z.object({
|
|
6189
|
+
type: import_zod9.z.literal("addCheckConstraint"),
|
|
6190
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6191
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6192
|
+
expression: import_zod9.z.string().min(1)
|
|
6159
6193
|
}),
|
|
6160
|
-
|
|
6161
|
-
type:
|
|
6162
|
-
table:
|
|
6163
|
-
name:
|
|
6164
|
-
cascade:
|
|
6165
|
-
ifExists:
|
|
6194
|
+
import_zod9.z.object({
|
|
6195
|
+
type: import_zod9.z.literal("dropConstraint"),
|
|
6196
|
+
table: import_zod9.z.string().min(1).max(63),
|
|
6197
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6198
|
+
cascade: import_zod9.z.boolean().optional(),
|
|
6199
|
+
ifExists: import_zod9.z.boolean().optional()
|
|
6166
6200
|
}),
|
|
6167
6201
|
// Enum types
|
|
6168
|
-
|
|
6169
|
-
type:
|
|
6170
|
-
name:
|
|
6171
|
-
values:
|
|
6202
|
+
import_zod9.z.object({
|
|
6203
|
+
type: import_zod9.z.literal("createEnum"),
|
|
6204
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6205
|
+
values: import_zod9.z.array(import_zod9.z.string().min(1)).min(1)
|
|
6172
6206
|
}),
|
|
6173
|
-
|
|
6174
|
-
type:
|
|
6175
|
-
name:
|
|
6176
|
-
value:
|
|
6207
|
+
import_zod9.z.object({
|
|
6208
|
+
type: import_zod9.z.literal("alterEnumAddValue"),
|
|
6209
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6210
|
+
value: import_zod9.z.string().min(1),
|
|
6177
6211
|
/** Position the new value before an existing one (mutually exclusive with `after`) */
|
|
6178
|
-
before:
|
|
6212
|
+
before: import_zod9.z.string().optional(),
|
|
6179
6213
|
/** Position the new value after an existing one (mutually exclusive with `before`) */
|
|
6180
|
-
after:
|
|
6181
|
-
ifNotExists:
|
|
6214
|
+
after: import_zod9.z.string().optional(),
|
|
6215
|
+
ifNotExists: import_zod9.z.boolean().optional()
|
|
6182
6216
|
}),
|
|
6183
|
-
|
|
6184
|
-
type:
|
|
6185
|
-
name:
|
|
6186
|
-
cascade:
|
|
6187
|
-
ifExists:
|
|
6217
|
+
import_zod9.z.object({
|
|
6218
|
+
type: import_zod9.z.literal("dropEnum"),
|
|
6219
|
+
name: import_zod9.z.string().min(1).max(63),
|
|
6220
|
+
cascade: import_zod9.z.boolean().optional(),
|
|
6221
|
+
ifExists: import_zod9.z.boolean().optional()
|
|
6188
6222
|
}),
|
|
6189
6223
|
// Extensions
|
|
6190
|
-
|
|
6191
|
-
type:
|
|
6192
|
-
name:
|
|
6193
|
-
ifNotExists:
|
|
6224
|
+
import_zod9.z.object({
|
|
6225
|
+
type: import_zod9.z.literal("createExtension"),
|
|
6226
|
+
name: import_zod9.z.string().min(1),
|
|
6227
|
+
ifNotExists: import_zod9.z.boolean().optional()
|
|
6194
6228
|
}),
|
|
6195
6229
|
// Data operations
|
|
6196
6230
|
/**
|
|
@@ -6198,26 +6232,26 @@ var schemaOpSchema = import_zod8.z.discriminatedUnion("type", [
|
|
|
6198
6232
|
* destructive — requires explicit confirm to replay on prod. The
|
|
6199
6233
|
* `description` is what the agent/user sees at confirm time.
|
|
6200
6234
|
*/
|
|
6201
|
-
|
|
6202
|
-
type:
|
|
6203
|
-
description:
|
|
6204
|
-
sql:
|
|
6235
|
+
import_zod9.z.object({
|
|
6236
|
+
type: import_zod9.z.literal("backfill"),
|
|
6237
|
+
description: import_zod9.z.string().min(1),
|
|
6238
|
+
sql: import_zod9.z.string().min(1)
|
|
6205
6239
|
}),
|
|
6206
6240
|
/**
|
|
6207
6241
|
* Escape hatch for DDL the structured ops can't express. `destructive`
|
|
6208
6242
|
* forces classification — use false only for genuinely additive-only SQL
|
|
6209
6243
|
* (e.g. CREATE EXTENSION variants the structured op doesn't cover).
|
|
6210
6244
|
*/
|
|
6211
|
-
|
|
6212
|
-
type:
|
|
6213
|
-
description:
|
|
6214
|
-
sql:
|
|
6215
|
-
destructive:
|
|
6245
|
+
import_zod9.z.object({
|
|
6246
|
+
type: import_zod9.z.literal("rawSql"),
|
|
6247
|
+
description: import_zod9.z.string().min(1),
|
|
6248
|
+
sql: import_zod9.z.string().min(1),
|
|
6249
|
+
destructive: import_zod9.z.boolean()
|
|
6216
6250
|
})
|
|
6217
6251
|
]);
|
|
6218
6252
|
|
|
6219
6253
|
// ../../packages/lib/src/server/module-rail/ops.ts
|
|
6220
|
-
var
|
|
6254
|
+
var import_zod10 = require("zod");
|
|
6221
6255
|
|
|
6222
6256
|
// ../../packages/lib/src/server/module-rail/reconcile.ts
|
|
6223
6257
|
var SANDBOX_BATCH_SIZE = 200;
|