@quickback-dev/cli 0.50.3 → 0.50.5
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/commands/deploy.d.ts +29 -0
- package/dist/commands/deploy.d.ts.map +1 -0
- package/dist/commands/deploy.js +324 -0
- package/dist/commands/deploy.js.map +1 -0
- package/dist/docs/content.d.ts.map +1 -1
- package/dist/docs/content.js +22 -17
- package/dist/docs/content.js.map +1 -1
- package/dist/index.js +10 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/config-id-splice.d.ts +68 -0
- package/dist/lib/config-id-splice.d.ts.map +1 -0
- package/dist/lib/config-id-splice.js +364 -0
- package/dist/lib/config-id-splice.js.map +1 -0
- package/dist/lib/config-id-splice.test.d.ts +2 -0
- package/dist/lib/config-id-splice.test.d.ts.map +1 -0
- package/dist/lib/config-id-splice.test.js +246 -0
- package/dist/lib/config-id-splice.test.js.map +1 -0
- package/dist/lib/shell.d.ts +14 -0
- package/dist/lib/shell.d.ts.map +1 -1
- package/dist/lib/shell.js +27 -0
- package/dist/lib/shell.js.map +1 -1
- package/dist/lib/wrangler-resources.d.ts +131 -0
- package/dist/lib/wrangler-resources.d.ts.map +1 -0
- package/dist/lib/wrangler-resources.js +355 -0
- package/dist/lib/wrangler-resources.js.map +1 -0
- package/dist/lib/wrangler-resources.test.d.ts +2 -0
- package/dist/lib/wrangler-resources.test.d.ts.map +1 -0
- package/dist/lib/wrangler-resources.test.js +321 -0
- package/dist/lib/wrangler-resources.test.js.map +1 -0
- package/dist/skill/docs/changelog.md +6 -0
- package/dist/skill/docs/compiler/cloud-compiler/deploy.md +82 -0
- package/dist/skill/docs/compiler/cloud-compiler/endpoints.md +23 -0
- package/dist/skill/docs/compiler/cloud-compiler/local-compiler.md +2 -0
- package/dist/skill/docs/compiler/config/index.md +5 -0
- package/dist/skill/docs/compiler/config/security.md +1 -0
- package/dist/skill/docs/compiler/definitions/access.md +1 -0
- package/dist/skill/docs/compiler/definitions/actions.md +27 -1
- package/dist/skill/docs/compiler/definitions/encryption.md +1 -0
- package/dist/skill/docs/compiler/definitions/feature.md +2 -0
- package/dist/skill/docs/compiler/definitions/masking.md +1 -0
- package/dist/skill/docs/compiler/getting-started/hand-crafted.md +8 -1
- package/dist/skill/docs/compiler/getting-started/patterns.md +1 -1
- package/dist/skill/docs/compiler/targets/hono-api/database/neon.md +11 -4
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/errors.md +1 -0
- package/dist/skill/docs/stack/account-ui/environment-variables.md +11 -0
- package/dist/skill/docs/stack/account-ui/with-quickback.md +2 -0
- package/dist/skill/docs/stack/auth/jwt-optimization.md +9 -0
- package/dist/skill/docs/stack/cms/connecting.md +5 -0
- package/dist/skill/docs/stack/realtime/index.md +23 -5
- package/package.json +1 -1
- package/src/skill/docs/changelog.md +6 -0
- package/src/skill/docs/compiler/cloud-compiler/deploy.md +82 -0
- package/src/skill/docs/compiler/cloud-compiler/endpoints.md +23 -0
- package/src/skill/docs/compiler/cloud-compiler/local-compiler.md +2 -0
- package/src/skill/docs/compiler/config/index.md +5 -0
- package/src/skill/docs/compiler/config/security.md +1 -0
- package/src/skill/docs/compiler/definitions/access.md +1 -0
- package/src/skill/docs/compiler/definitions/actions.md +27 -1
- package/src/skill/docs/compiler/definitions/encryption.md +1 -0
- package/src/skill/docs/compiler/definitions/feature.md +2 -0
- package/src/skill/docs/compiler/definitions/masking.md +1 -0
- package/src/skill/docs/compiler/getting-started/hand-crafted.md +8 -1
- package/src/skill/docs/compiler/getting-started/patterns.md +1 -1
- package/src/skill/docs/compiler/targets/hono-api/database/neon.md +11 -4
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/errors.md +1 -0
- package/src/skill/docs/stack/account-ui/environment-variables.md +11 -0
- package/src/skill/docs/stack/account-ui/with-quickback.md +2 -0
- package/src/skill/docs/stack/auth/jwt-optimization.md +9 -0
- package/src/skill/docs/stack/cms/connecting.md +5 -0
- package/src/skill/docs/stack/realtime/index.md +23 -5
|
@@ -0,0 +1,355 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wrangler Resource Provisioning
|
|
3
|
+
*
|
|
4
|
+
* Pure logic + a thin wrangler client for `quickback deploy`:
|
|
5
|
+
*
|
|
6
|
+
* - parse the compiler-generated wrangler.toml for D1 / KV / R2 / Hyperdrive
|
|
7
|
+
* sections
|
|
8
|
+
* - detect the compiler's placeholder ids — self-describing
|
|
9
|
+
* `placeholder-*` values plus the legacy `local`/`local-*` set (see
|
|
10
|
+
* apps/compiler/src/constants/placeholders.ts, the source of truth for
|
|
11
|
+
* this predicate; the compiler emits these whenever the corresponding
|
|
12
|
+
* provider-config key is unset)
|
|
13
|
+
* - map each placeholder back to the quickback.config.ts provider-config
|
|
14
|
+
* key the compiler reads the real id from
|
|
15
|
+
* - parse `wrangler d1 create` / `wrangler kv namespace create` output
|
|
16
|
+
* (both the JSON snippet emitted by current wrangler and the legacy
|
|
17
|
+
* TOML snippet)
|
|
18
|
+
*
|
|
19
|
+
* All Cloudflare calls go through an injected {@link CaptureRunner} so
|
|
20
|
+
* tests never touch the network.
|
|
21
|
+
*/
|
|
22
|
+
/**
|
|
23
|
+
* Line-based parser for the compiler-emitted wrangler.toml. Tracks the
|
|
24
|
+
* current `[[table]]` header and collects `key = "value"` pairs until the
|
|
25
|
+
* next header. Deliberately minimal — it only needs to understand the
|
|
26
|
+
* shape our own config generator emits.
|
|
27
|
+
*/
|
|
28
|
+
export function parseWranglerToml(toml) {
|
|
29
|
+
const resources = { d1: [], kv: [], r2: [], hyperdrive: [] };
|
|
30
|
+
let section = null;
|
|
31
|
+
let current = {};
|
|
32
|
+
const flush = () => {
|
|
33
|
+
if (!section)
|
|
34
|
+
return;
|
|
35
|
+
if (section === 'd1_databases') {
|
|
36
|
+
resources.d1.push({
|
|
37
|
+
binding: current.binding ?? '',
|
|
38
|
+
databaseName: current.database_name ?? '',
|
|
39
|
+
databaseId: current.database_id ?? '',
|
|
40
|
+
migrationsDir: current.migrations_dir,
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
else if (section === 'kv_namespaces') {
|
|
44
|
+
resources.kv.push({ binding: current.binding ?? '', id: current.id ?? '' });
|
|
45
|
+
}
|
|
46
|
+
else if (section === 'r2_buckets') {
|
|
47
|
+
resources.r2.push({ binding: current.binding ?? '', bucketName: current.bucket_name ?? '' });
|
|
48
|
+
}
|
|
49
|
+
else if (section === 'hyperdrive') {
|
|
50
|
+
resources.hyperdrive.push({ binding: current.binding ?? '', id: current.id ?? '' });
|
|
51
|
+
}
|
|
52
|
+
current = {};
|
|
53
|
+
};
|
|
54
|
+
for (const rawLine of toml.split('\n')) {
|
|
55
|
+
const line = rawLine.trim();
|
|
56
|
+
if (line.startsWith('#') || line.length === 0)
|
|
57
|
+
continue;
|
|
58
|
+
const arrayHeader = line.match(/^\[\[([A-Za-z0-9_.]+)\]\]$/);
|
|
59
|
+
if (arrayHeader) {
|
|
60
|
+
flush();
|
|
61
|
+
section = arrayHeader[1];
|
|
62
|
+
continue;
|
|
63
|
+
}
|
|
64
|
+
const tableHeader = line.match(/^\[([A-Za-z0-9_.]+)\]$/);
|
|
65
|
+
if (tableHeader) {
|
|
66
|
+
flush();
|
|
67
|
+
section = null; // plain tables ([assets], [ai], …) aren't resources we track
|
|
68
|
+
continue;
|
|
69
|
+
}
|
|
70
|
+
const kv = line.match(/^([A-Za-z0-9_]+)\s*=\s*"((?:[^"\\]|\\.)*)"/);
|
|
71
|
+
if (!kv)
|
|
72
|
+
continue;
|
|
73
|
+
if (section) {
|
|
74
|
+
current[kv[1]] = kv[2];
|
|
75
|
+
}
|
|
76
|
+
else if (kv[1] === 'name' && resources.workerName === undefined) {
|
|
77
|
+
resources.workerName = kv[2];
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
flush();
|
|
81
|
+
return resources;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Placeholder id predicate — replicated from
|
|
85
|
+
* apps/compiler/src/constants/placeholders.ts (the compiler's source of
|
|
86
|
+
* truth; the CLI can't import across packages at runtime, keep in sync).
|
|
87
|
+
*
|
|
88
|
+
* Two placeholder generations exist in the wild:
|
|
89
|
+
* - self-describing: any id starting with `placeholder-`
|
|
90
|
+
* (e.g. `placeholder-1-auth-db-id`, `placeholder-3-kv-namespace-id`)
|
|
91
|
+
* - legacy: exactly `local`, `local-auth`, `local-features`,
|
|
92
|
+
* `local-files`, `local-webhooks` (all projects compiled before the
|
|
93
|
+
* rename)
|
|
94
|
+
*
|
|
95
|
+
* Real ids are UUIDs (D1) or 32-char hex (KV) — never either shape.
|
|
96
|
+
*/
|
|
97
|
+
const PLACEHOLDER_ID_PREFIX = 'placeholder-';
|
|
98
|
+
const LEGACY_PLACEHOLDER_IDS = new Set([
|
|
99
|
+
'local',
|
|
100
|
+
'local-auth',
|
|
101
|
+
'local-features',
|
|
102
|
+
'local-files',
|
|
103
|
+
'local-webhooks',
|
|
104
|
+
]);
|
|
105
|
+
export function isPlaceholderId(id) {
|
|
106
|
+
if (!id)
|
|
107
|
+
return true;
|
|
108
|
+
return id.startsWith(PLACEHOLDER_ID_PREFIX) || LEGACY_PLACEHOLDER_IDS.has(id);
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* quickback.config.ts key (under providers.database.config) that the
|
|
112
|
+
* compiler reads each D1 id from, keyed by the placeholder literal it
|
|
113
|
+
* emits when that key is unset. Covers both placeholder generations —
|
|
114
|
+
* see apps/compiler/src/constants/placeholders.ts and
|
|
115
|
+
* apps/compiler/src/generators/config.ts.
|
|
116
|
+
*/
|
|
117
|
+
const CONFIG_KEY_BY_PLACEHOLDER = {
|
|
118
|
+
// Self-describing placeholders (current compiler)
|
|
119
|
+
'placeholder-1-auth-db-id': 'authDatabaseId',
|
|
120
|
+
'placeholder-2-features-db-id': 'featuresDatabaseId',
|
|
121
|
+
'placeholder-4-files-db-id': 'filesDatabaseId',
|
|
122
|
+
'placeholder-5-webhooks-db-id': 'webhooksDatabaseId',
|
|
123
|
+
'placeholder-1-db-id': 'databaseId', // single-database (non-split) projects
|
|
124
|
+
// Legacy placeholders (projects compiled before the rename)
|
|
125
|
+
'local-auth': 'authDatabaseId',
|
|
126
|
+
'local-features': 'featuresDatabaseId',
|
|
127
|
+
'local-files': 'filesDatabaseId',
|
|
128
|
+
'local-webhooks': 'webhooksDatabaseId',
|
|
129
|
+
local: 'databaseId',
|
|
130
|
+
};
|
|
131
|
+
/** Fallback mapping by binding name when the placeholder isn't one of ours. */
|
|
132
|
+
const CONFIG_KEY_BY_BINDING = {
|
|
133
|
+
AUTH_DB: 'authDatabaseId',
|
|
134
|
+
DB: 'featuresDatabaseId',
|
|
135
|
+
FILES_DB: 'filesDatabaseId',
|
|
136
|
+
WEBHOOKS_DB: 'webhooksDatabaseId',
|
|
137
|
+
AUDIT_DB: 'auditDatabaseId',
|
|
138
|
+
DATABASE: 'databaseId',
|
|
139
|
+
};
|
|
140
|
+
/**
|
|
141
|
+
* Resolve which providers.database.config key should receive the real id
|
|
142
|
+
* for a D1 section. Placeholder literal first (stable across binding
|
|
143
|
+
* renames), binding name as fallback.
|
|
144
|
+
*/
|
|
145
|
+
export function configKeyForD1(entry) {
|
|
146
|
+
const byPlaceholder = CONFIG_KEY_BY_PLACEHOLDER[entry.databaseId];
|
|
147
|
+
if (byPlaceholder)
|
|
148
|
+
return byPlaceholder;
|
|
149
|
+
return CONFIG_KEY_BY_BINDING[entry.binding] ?? null;
|
|
150
|
+
}
|
|
151
|
+
export function buildProvisionPlan(resources) {
|
|
152
|
+
const d1ToProvision = resources.d1.filter((d) => isPlaceholderId(d.databaseId));
|
|
153
|
+
const d1Ready = resources.d1.filter((d) => !isPlaceholderId(d.databaseId));
|
|
154
|
+
const kvToProvision = resources.kv.filter((k) => isPlaceholderId(k.id));
|
|
155
|
+
const kvReady = resources.kv.filter((k) => !isPlaceholderId(k.id));
|
|
156
|
+
const hyperdriveUnresolved = resources.hyperdrive.filter((h) => isPlaceholderId(h.id));
|
|
157
|
+
return {
|
|
158
|
+
d1ToProvision,
|
|
159
|
+
d1Ready,
|
|
160
|
+
kvToProvision,
|
|
161
|
+
kvReady,
|
|
162
|
+
r2ToEnsure: resources.r2,
|
|
163
|
+
hyperdriveUnresolved,
|
|
164
|
+
hasWork: d1ToProvision.length > 0 || kvToProvision.length > 0 || resources.r2.length > 0,
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
// ─── wrangler output parsing ────────────────────────────────────────────────
|
|
168
|
+
const UUID_RE = /[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}/;
|
|
169
|
+
/**
|
|
170
|
+
* Extract the database id from `wrangler d1 create` output. Handles the
|
|
171
|
+
* JSON snippet emitted by current wrangler versions and the legacy TOML
|
|
172
|
+
* snippet; falls back to the first UUID anywhere in the output.
|
|
173
|
+
*/
|
|
174
|
+
export function parseD1CreateOutput(output) {
|
|
175
|
+
const json = output.match(/"database_id"\s*:\s*"([^"]+)"/);
|
|
176
|
+
if (json)
|
|
177
|
+
return json[1];
|
|
178
|
+
const toml = output.match(/database_id\s*=\s*"([^"]+)"/);
|
|
179
|
+
if (toml)
|
|
180
|
+
return toml[1];
|
|
181
|
+
const uuid = output.match(UUID_RE);
|
|
182
|
+
return uuid ? uuid[0] : null;
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Extract the namespace id from `wrangler kv namespace create` output.
|
|
186
|
+
* Handles JSON and TOML snippet forms; falls back to the first 32-char
|
|
187
|
+
* hex token.
|
|
188
|
+
*/
|
|
189
|
+
export function parseKvCreateOutput(output) {
|
|
190
|
+
const json = output.match(/"id"\s*:\s*"([0-9a-fA-F]{32})"/);
|
|
191
|
+
if (json)
|
|
192
|
+
return json[1];
|
|
193
|
+
const toml = output.match(/\bid\s*=\s*"([0-9a-fA-F]{32})"/);
|
|
194
|
+
if (toml)
|
|
195
|
+
return toml[1];
|
|
196
|
+
const hex = output.match(/\b[0-9a-fA-F]{32}\b/);
|
|
197
|
+
return hex ? hex[0] : null;
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* Parse a JSON payload out of possibly-noisy CLI output (wrangler prints
|
|
201
|
+
* banners/warnings around the JSON). Finds the outermost array.
|
|
202
|
+
*/
|
|
203
|
+
function parseJsonArray(output) {
|
|
204
|
+
const start = output.indexOf('[');
|
|
205
|
+
const end = output.lastIndexOf(']');
|
|
206
|
+
if (start === -1 || end === -1 || end <= start)
|
|
207
|
+
return null;
|
|
208
|
+
try {
|
|
209
|
+
const parsed = JSON.parse(output.slice(start, end + 1));
|
|
210
|
+
return Array.isArray(parsed) ? parsed : null;
|
|
211
|
+
}
|
|
212
|
+
catch {
|
|
213
|
+
return null;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
/** `wrangler d1 list --json` → Map of database name → uuid. */
|
|
217
|
+
export function parseD1ListOutput(output) {
|
|
218
|
+
const map = new Map();
|
|
219
|
+
const rows = parseJsonArray(output) ?? [];
|
|
220
|
+
for (const row of rows) {
|
|
221
|
+
if (row && typeof row === 'object') {
|
|
222
|
+
const r = row;
|
|
223
|
+
const name = typeof r.name === 'string' ? r.name : undefined;
|
|
224
|
+
const id = typeof r.uuid === 'string' ? r.uuid :
|
|
225
|
+
typeof r.database_id === 'string' ? r.database_id :
|
|
226
|
+
typeof r.id === 'string' ? r.id : undefined;
|
|
227
|
+
if (name && id)
|
|
228
|
+
map.set(name, id);
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
return map;
|
|
232
|
+
}
|
|
233
|
+
/** `wrangler kv namespace list` → Map of namespace title → id. */
|
|
234
|
+
export function parseKvListOutput(output) {
|
|
235
|
+
const map = new Map();
|
|
236
|
+
const rows = parseJsonArray(output) ?? [];
|
|
237
|
+
for (const row of rows) {
|
|
238
|
+
if (row && typeof row === 'object') {
|
|
239
|
+
const r = row;
|
|
240
|
+
if (typeof r.title === 'string' && typeof r.id === 'string')
|
|
241
|
+
map.set(r.title, r.id);
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
return map;
|
|
245
|
+
}
|
|
246
|
+
export class WranglerError extends Error {
|
|
247
|
+
result;
|
|
248
|
+
constructor(message, result) {
|
|
249
|
+
super(message);
|
|
250
|
+
this.result = result;
|
|
251
|
+
this.name = 'WranglerError';
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
function combined(result) {
|
|
255
|
+
return `${result.stdout}\n${result.stderr}`;
|
|
256
|
+
}
|
|
257
|
+
export class WranglerClient {
|
|
258
|
+
runner;
|
|
259
|
+
cwd;
|
|
260
|
+
constructor(runner, cwd) {
|
|
261
|
+
this.runner = runner;
|
|
262
|
+
this.cwd = cwd;
|
|
263
|
+
}
|
|
264
|
+
run(args) {
|
|
265
|
+
return this.runner(args, { cwd: this.cwd });
|
|
266
|
+
}
|
|
267
|
+
/** Returns the wrangler version string, or null when wrangler isn't runnable. */
|
|
268
|
+
async version() {
|
|
269
|
+
try {
|
|
270
|
+
const result = await this.run(['--version']);
|
|
271
|
+
if (result.code !== 0)
|
|
272
|
+
return null;
|
|
273
|
+
const match = combined(result).match(/(\d+\.\d+\.\d+)/);
|
|
274
|
+
return match ? match[1] : combined(result).trim() || 'unknown';
|
|
275
|
+
}
|
|
276
|
+
catch {
|
|
277
|
+
return null;
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
/** Checks `wrangler whoami`. */
|
|
281
|
+
async whoami() {
|
|
282
|
+
const result = await this.run(['whoami']);
|
|
283
|
+
const out = combined(result);
|
|
284
|
+
if (result.code !== 0 || /not authenticated/i.test(out)) {
|
|
285
|
+
return { ok: false, detail: out.trim() };
|
|
286
|
+
}
|
|
287
|
+
const email = out.match(/email\s+['"]?([\w.+-]+@[\w-]+(?:\.[\w-]+)+)/);
|
|
288
|
+
return { ok: true, detail: email ? email[1] : 'authenticated' };
|
|
289
|
+
}
|
|
290
|
+
/** Map of existing D1 database name → uuid. */
|
|
291
|
+
async d1List() {
|
|
292
|
+
const result = await this.run(['d1', 'list', '--json']);
|
|
293
|
+
if (result.code !== 0) {
|
|
294
|
+
throw new WranglerError(`wrangler d1 list failed:\n${combined(result).trim()}`, result);
|
|
295
|
+
}
|
|
296
|
+
return parseD1ListOutput(result.stdout);
|
|
297
|
+
}
|
|
298
|
+
/** Creates a D1 database and returns its id. Falls back to a list lookup when the output can't be parsed. */
|
|
299
|
+
async d1Create(name) {
|
|
300
|
+
const result = await this.run(['d1', 'create', name]);
|
|
301
|
+
const out = combined(result);
|
|
302
|
+
if (result.code !== 0 && !/already exists/i.test(out)) {
|
|
303
|
+
throw new WranglerError(`wrangler d1 create ${name} failed:\n${out.trim()}`, result);
|
|
304
|
+
}
|
|
305
|
+
const id = parseD1CreateOutput(result.stdout) ?? parseD1CreateOutput(out);
|
|
306
|
+
if (id)
|
|
307
|
+
return id;
|
|
308
|
+
const listed = (await this.d1List()).get(name);
|
|
309
|
+
if (listed)
|
|
310
|
+
return listed;
|
|
311
|
+
throw new WranglerError(`Created D1 database '${name}' but could not determine its id from wrangler output.`, result);
|
|
312
|
+
}
|
|
313
|
+
/** Map of existing KV namespace title → id. */
|
|
314
|
+
async kvList() {
|
|
315
|
+
const result = await this.run(['kv', 'namespace', 'list']);
|
|
316
|
+
if (result.code !== 0) {
|
|
317
|
+
throw new WranglerError(`wrangler kv namespace list failed:\n${combined(result).trim()}`, result);
|
|
318
|
+
}
|
|
319
|
+
return parseKvListOutput(result.stdout);
|
|
320
|
+
}
|
|
321
|
+
/** Creates a KV namespace for `binding` and returns its id. */
|
|
322
|
+
async kvCreate(binding, expectedTitle) {
|
|
323
|
+
const result = await this.run(['kv', 'namespace', 'create', binding]);
|
|
324
|
+
const out = combined(result);
|
|
325
|
+
if (result.code !== 0 && !/already exists/i.test(out)) {
|
|
326
|
+
throw new WranglerError(`wrangler kv namespace create ${binding} failed:\n${out.trim()}`, result);
|
|
327
|
+
}
|
|
328
|
+
const id = parseKvCreateOutput(result.stdout) ?? parseKvCreateOutput(out);
|
|
329
|
+
if (id)
|
|
330
|
+
return id;
|
|
331
|
+
const listed = (await this.kvList()).get(expectedTitle);
|
|
332
|
+
if (listed)
|
|
333
|
+
return listed;
|
|
334
|
+
throw new WranglerError(`Created KV namespace '${expectedTitle}' but could not determine its id from wrangler output.`, result);
|
|
335
|
+
}
|
|
336
|
+
/** True when the R2 bucket already exists. */
|
|
337
|
+
async r2Exists(bucketName) {
|
|
338
|
+
const result = await this.run(['r2', 'bucket', 'list']);
|
|
339
|
+
if (result.code !== 0)
|
|
340
|
+
return false; // fall through to create-and-tolerate
|
|
341
|
+
const re = new RegExp(`(^|[\\s"'])${bucketName.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')}($|[\\s"',])`, 'm');
|
|
342
|
+
return re.test(combined(result));
|
|
343
|
+
}
|
|
344
|
+
/** Creates an R2 bucket; treats "already exists" as success. */
|
|
345
|
+
async r2Create(bucketName) {
|
|
346
|
+
const result = await this.run(['r2', 'bucket', 'create', bucketName]);
|
|
347
|
+
if (result.code === 0)
|
|
348
|
+
return 'created';
|
|
349
|
+
const out = combined(result);
|
|
350
|
+
if (/already exists|already owned|already has a bucket/i.test(out))
|
|
351
|
+
return 'exists';
|
|
352
|
+
throw new WranglerError(`wrangler r2 bucket create ${bucketName} failed:\n${out.trim()}`, result);
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
//# sourceMappingURL=wrangler-resources.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wrangler-resources.js","sourceRoot":"","sources":["../../src/lib/wrangler-resources.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAiCH;;;;;GAKG;AACH,MAAM,UAAU,iBAAiB,CAAC,IAAY;IAC5C,MAAM,SAAS,GAAsB,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,CAAC;IAEhF,IAAI,OA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