@guren/plugin-cloudflare 0.3.0 → 0.3.2
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/build-DxgM3l-5.js +294 -0
- package/dist/commands.d.ts +13 -14
- package/dist/commands.js +25 -33
- package/dist/index.d.ts +155 -152
- package/dist/index.js +341 -348
- package/package.json +5 -5
- package/dist/chunk-32YY6FCY.js +0 -262
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
import { cpSync, existsSync, mkdirSync, readFileSync, readdirSync, rmSync, writeFileSync } from "node:fs";
|
|
2
|
+
import { relative, resolve, sep } from "node:path";
|
|
3
|
+
import { pathToFileURL } from "node:url";
|
|
4
|
+
import { DEV_ONLY_MODULES, SQL_CLIENT_MODULES, assertOutputDirOutsideRoot, importSpecifier, renderDevOnlyStub, resetOutputDir, resolveClientAssetEnv, resolvePathLike, resolveSsrEntryFile, stageStaticAssets } from "@guren/core/internal/deploy-build";
|
|
5
|
+
//#region src/build.ts
|
|
6
|
+
/**
|
|
7
|
+
* Assemble a deployable Cloudflare Workers directory (`.cloudflare/`) from a
|
|
8
|
+
* built Guren app: a generated worker entry that statically wires the SSR
|
|
9
|
+
* bundle, static assets for Workers Static Assets, and a one-time
|
|
10
|
+
* `wrangler.jsonc` scaffold. Deploy with `wrangler deploy`.
|
|
11
|
+
*/
|
|
12
|
+
async function buildCloudflareOutput(options = {}) {
|
|
13
|
+
const root = resolvePathLike(options.rootDir ?? process.cwd());
|
|
14
|
+
const out = resolvePathLike(options.outputDir ?? resolve(root, ".cloudflare"));
|
|
15
|
+
const appEntry = resolvePathLike(options.appEntry ?? resolve(root, "src/app.ts"));
|
|
16
|
+
const publicDir = resolvePathLike(options.publicDir ?? resolve(root, "public"));
|
|
17
|
+
const ssrDir = resolvePathLike(options.ssrDir ?? resolve(root, ".guren/ssr"));
|
|
18
|
+
const clientEntryKey = options.clientEntryKey ?? "resources/js/app.tsx";
|
|
19
|
+
const ssrEntryKey = options.ssrEntryKey ?? "resources/js/ssr.tsx";
|
|
20
|
+
assertOutputDirOutsideRoot(out, root, "Cloudflare build");
|
|
21
|
+
const packageJson = readPackageJson(root);
|
|
22
|
+
if (!options.skipAppBuild) runAppBuild(root, packageJson.scripts ?? {});
|
|
23
|
+
if (!existsSync(appEntry)) throw new Error(`Cloudflare build: app entry not found at ${appEntry}. Pass "appEntry" if your Application lives elsewhere.`);
|
|
24
|
+
const ssrImport = await resolveSsrImport(ssrDir, ssrEntryKey);
|
|
25
|
+
const assetEnv = resolveClientAssetEnv(publicDir, clientEntryKey, "Cloudflare build");
|
|
26
|
+
resetOutputDir(out, root, "Cloudflare build");
|
|
27
|
+
stageStaticAssets(publicDir, resolve(out, "assets"));
|
|
28
|
+
writeFileSync(resolve(out, "worker.js"), renderWorkerModule({
|
|
29
|
+
out,
|
|
30
|
+
appEntry,
|
|
31
|
+
ssrImport,
|
|
32
|
+
assetEnv
|
|
33
|
+
}));
|
|
34
|
+
flattenD1Migrations(resolve(root, "db/migrations"), resolve(out, "d1-migrations"));
|
|
35
|
+
writeDevOnlyStubs(out);
|
|
36
|
+
scaffoldWranglerConfig(root, out, packageJson.name);
|
|
37
|
+
}
|
|
38
|
+
const MCP_UNAVAILABLE = "The MCP endpoint is unavailable on Cloudflare Workers — it generates files on disk.";
|
|
39
|
+
/**
|
|
40
|
+
* Why the dev-only modules in `DEV_ONLY_MODULES` cannot run here, worded for
|
|
41
|
+
* this platform: each names the Workers-appropriate replacement.
|
|
42
|
+
*/
|
|
43
|
+
/**
|
|
44
|
+
* Both lists: on Workers the SQL clients are as unreachable as the dev-only
|
|
45
|
+
* modules, because D1 is the only database the platform has.
|
|
46
|
+
*/
|
|
47
|
+
const STUBBED_MODULES = [...DEV_ONLY_MODULES, ...SQL_CLIENT_MODULES];
|
|
48
|
+
const UNAVAILABLE_ON_WORKERS = {
|
|
49
|
+
sqlite: "bun:sqlite is unavailable on Cloudflare Workers — use createD1Database().",
|
|
50
|
+
vite: "The Vite dev server is unavailable on Cloudflare Workers — assets are served by Workers Static Assets.",
|
|
51
|
+
mcp: MCP_UNAVAILABLE,
|
|
52
|
+
"sql-driver": "This database client is unavailable on Cloudflare Workers — use createD1Database(). It is stubbed because @guren/orm names it in a dynamic import that bundlers follow even when the branch cannot be taken."
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Wrangler resolves an `alias` to a path on disk, so unlike a bundler plugin
|
|
56
|
+
* each stub needs a file of its own. The names are deliberately hand-written
|
|
57
|
+
* rather than derived: they are baked into every app's committed
|
|
58
|
+
* `wrangler.jsonc`, which the scaffold never overwrites, so deriving them
|
|
59
|
+
* would rename files out from under existing apps for no benefit.
|
|
60
|
+
*
|
|
61
|
+
* Keyed on `DevOnlySpecifier`, so adding an entry to `DEV_ONLY_MODULES` is a
|
|
62
|
+
* compile error here until it gets a filename — the drift a derived name would
|
|
63
|
+
* have prevented, caught by the type system instead.
|
|
64
|
+
*/
|
|
65
|
+
const STUB_FILES = {
|
|
66
|
+
"bun:sqlite": "stub-bun-sqlite.js",
|
|
67
|
+
vite: "stub-vite.js",
|
|
68
|
+
"@guren/cli": "stub-guren-cli.js",
|
|
69
|
+
"@modelcontextprotocol/sdk/server/mcp.js": "stub-mcp-server.js",
|
|
70
|
+
"@modelcontextprotocol/sdk/server/webStandardStreamableHttp.js": "stub-mcp-transport.js",
|
|
71
|
+
postgres: "stub-postgres.js",
|
|
72
|
+
mysql2: "stub-mysql2.js",
|
|
73
|
+
"mysql2/promise": "stub-mysql2-promise.js",
|
|
74
|
+
"@aws-sdk/client-rds-data": "stub-rds-data.js"
|
|
75
|
+
};
|
|
76
|
+
function writeDevOnlyStubs(out) {
|
|
77
|
+
for (const module of STUBBED_MODULES) writeFileSync(resolve(out, STUB_FILES[module.specifier]), renderDevOnlyStub(module, UNAVAILABLE_ON_WORKERS[module.kind]));
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* A package-name alias does not cover subpaths, so every stubbed specifier —
|
|
81
|
+
* including each MCP SDK subpath — needs its own entry. Unlike the Lambda
|
|
82
|
+
* plugin's bundler hook, wrangler cannot match a prefix, so an SDK subpath
|
|
83
|
+
* added upstream needs a new `DEV_ONLY_MODULES` entry to stay stubbed here.
|
|
84
|
+
*/
|
|
85
|
+
function devOnlyAliases(outRelative) {
|
|
86
|
+
return Object.fromEntries(STUBBED_MODULES.map((module) => [module.specifier, `./${outRelative}/${STUB_FILES[module.specifier]}`]));
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* Wrangler's `migrations_dir` only discovers flat `*.sql` files, but
|
|
90
|
+
* drizzle-kit (1.x) emits one `<timestamp>_<name>/migration.sql` folder per
|
|
91
|
+
* migration. Flatten each folder into `<folder-name>.sql` (plain `*.sql`
|
|
92
|
+
* files pass through unchanged, `meta/` bookkeeping is skipped) so
|
|
93
|
+
* `wrangler d1 migrations apply` sees them in filename order. Regenerated on
|
|
94
|
+
* every build — run `cloudflare:build` after adding a migration.
|
|
95
|
+
*/
|
|
96
|
+
function flattenD1Migrations(migrationsDir, outDir) {
|
|
97
|
+
if (!existsSync(migrationsDir)) return;
|
|
98
|
+
const entries = readdirSync(migrationsDir, { withFileTypes: true });
|
|
99
|
+
const copies = [];
|
|
100
|
+
for (const entry of entries) {
|
|
101
|
+
if (entry.isFile() && entry.name.endsWith(".sql")) {
|
|
102
|
+
copies.push({
|
|
103
|
+
from: resolve(migrationsDir, entry.name),
|
|
104
|
+
to: entry.name
|
|
105
|
+
});
|
|
106
|
+
continue;
|
|
107
|
+
}
|
|
108
|
+
if (entry.isDirectory() && entry.name !== "meta") {
|
|
109
|
+
const nested = resolve(migrationsDir, entry.name, "migration.sql");
|
|
110
|
+
if (existsSync(nested)) copies.push({
|
|
111
|
+
from: nested,
|
|
112
|
+
to: `${entry.name}.sql`
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
const seen = /* @__PURE__ */ new Map();
|
|
117
|
+
for (const copy of copies) {
|
|
118
|
+
const clash = seen.get(copy.to);
|
|
119
|
+
if (clash) throw new Error(`Cloudflare build: migrations "${clash}" and "${copy.from}" both flatten to "${copy.to}". Rename one so wrangler sees a stable order.`);
|
|
120
|
+
seen.set(copy.to, copy.from);
|
|
121
|
+
}
|
|
122
|
+
if (existsSync(outDir)) rmSync(outDir, {
|
|
123
|
+
recursive: true,
|
|
124
|
+
force: true
|
|
125
|
+
});
|
|
126
|
+
if (copies.length === 0) return;
|
|
127
|
+
mkdirSync(outDir, { recursive: true });
|
|
128
|
+
for (const copy of copies) cpSync(copy.from, resolve(outDir, copy.to));
|
|
129
|
+
}
|
|
130
|
+
function readPackageJson(root) {
|
|
131
|
+
const packageJsonPath = resolve(root, "package.json");
|
|
132
|
+
if (!existsSync(packageJsonPath)) return {};
|
|
133
|
+
try {
|
|
134
|
+
return JSON.parse(readFileSync(packageJsonPath, "utf8"));
|
|
135
|
+
} catch {
|
|
136
|
+
return {};
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
function runAppBuild(root, scripts) {
|
|
140
|
+
if (!scripts.build) throw new Error("Cloudflare build: no \"build\" script found in package.json. Add one (codegen + vite build + vite build --ssr) or pass --skip-app-build after building manually.");
|
|
141
|
+
if (Bun.spawnSync({
|
|
142
|
+
cmd: [
|
|
143
|
+
"bun",
|
|
144
|
+
"run",
|
|
145
|
+
"build"
|
|
146
|
+
],
|
|
147
|
+
cwd: root,
|
|
148
|
+
stdout: "inherit",
|
|
149
|
+
stderr: "inherit"
|
|
150
|
+
}).exitCode !== 0) throw new Error("Cloudflare build: the app \"build\" script failed.");
|
|
151
|
+
}
|
|
152
|
+
async function resolveSsrImport(ssrDir, ssrEntryKey) {
|
|
153
|
+
const file = resolveSsrEntryFile(ssrDir, ssrEntryKey, "Cloudflare build");
|
|
154
|
+
if (!file) {
|
|
155
|
+
console.warn(`Cloudflare build: no SSR manifest entry for "${ssrEntryKey}" under ${ssrDir}; generating a CSR-only worker.`);
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
const module = await import(pathToFileURL(file).href);
|
|
159
|
+
const rendererExport = ["render", "default"].find((name) => typeof module[name] === "function");
|
|
160
|
+
if (!rendererExport) throw new Error(`Cloudflare build: SSR entry ${file} does not export a renderer (expected a named "render" or default export).`);
|
|
161
|
+
return {
|
|
162
|
+
file,
|
|
163
|
+
rendererExport
|
|
164
|
+
};
|
|
165
|
+
}
|
|
166
|
+
function renderWorkerModule(input) {
|
|
167
|
+
const lines = ["// Generated by `guren cloudflare:build`. Do not edit — regenerate instead.", "import { createWorkersHandler } from '@guren/plugin-cloudflare'"];
|
|
168
|
+
if (input.ssrImport) lines.push("import { setInertiaSsrRenderer } from '@guren/core'", `import * as ssrModule from ${JSON.stringify(importSpecifier(input.out, input.ssrImport.file, "Cloudflare build"))}`);
|
|
169
|
+
lines.push(`import app from ${JSON.stringify(importSpecifier(input.out, input.appEntry, "Cloudflare build"))}`, "");
|
|
170
|
+
if (input.assetEnv.entry) lines.push(`process.env.GUREN_INERTIA_ENTRY = ${JSON.stringify(input.assetEnv.entry)}`);
|
|
171
|
+
if (input.assetEnv.styles) lines.push(`process.env.GUREN_INERTIA_STYLES = ${JSON.stringify(input.assetEnv.styles)}`);
|
|
172
|
+
if (input.assetEnv.entry || input.assetEnv.styles) lines.push("");
|
|
173
|
+
if (input.ssrImport) lines.push(`setInertiaSsrRenderer(ssrModule.${input.ssrImport.rendererExport})`, "");
|
|
174
|
+
lines.push("export default createWorkersHandler(app)", "");
|
|
175
|
+
return lines.join("\n");
|
|
176
|
+
}
|
|
177
|
+
function scaffoldWranglerConfig(root, out, packageName) {
|
|
178
|
+
const configPath = resolve(root, "wrangler.jsonc");
|
|
179
|
+
const appName = (packageName ?? "guren-app").replace(/^@[^/]+\//, "");
|
|
180
|
+
const outRelative = relative(root, out).split(sep).join("/");
|
|
181
|
+
const config = {
|
|
182
|
+
name: appName,
|
|
183
|
+
main: `${outRelative}/worker.js`,
|
|
184
|
+
compatibility_date: (/* @__PURE__ */ new Date()).toISOString().slice(0, 10),
|
|
185
|
+
compatibility_flags: ["nodejs_compat"],
|
|
186
|
+
alias: devOnlyAliases(outRelative),
|
|
187
|
+
define: {
|
|
188
|
+
"process.env.NODE_ENV": "\"production\"",
|
|
189
|
+
"import.meta.url": "\"file:///worker.js\""
|
|
190
|
+
},
|
|
191
|
+
assets: { directory: `${outRelative}/assets` },
|
|
192
|
+
d1_databases: [{
|
|
193
|
+
binding: "DB",
|
|
194
|
+
database_name: appName,
|
|
195
|
+
database_id: "TODO: wrangler d1 create",
|
|
196
|
+
migrations_dir: `${outRelative}/d1-migrations`
|
|
197
|
+
}],
|
|
198
|
+
vars: { NODE_ENV: "production" }
|
|
199
|
+
};
|
|
200
|
+
try {
|
|
201
|
+
writeFileSync(configPath, `${JSON.stringify(config, null, 2)}\n`, { flag: "wx" });
|
|
202
|
+
} catch (error) {
|
|
203
|
+
if (error.code === "EEXIST") {
|
|
204
|
+
warnMissingBuildOwnedKeys(configPath, outRelative);
|
|
205
|
+
return;
|
|
206
|
+
}
|
|
207
|
+
throw error;
|
|
208
|
+
}
|
|
209
|
+
console.log(`Cloudflare build: scaffolded ${configPath} — fill in d1_databases[0].database_id before deploying.`);
|
|
210
|
+
}
|
|
211
|
+
/**
|
|
212
|
+
* `wrangler.jsonc` is JSONC by name and by habit — the scaffold writes plain
|
|
213
|
+
* JSON, but every app that has touched the file since has comments in it, and
|
|
214
|
+
* `JSON.parse` rejects the first one. Reading it with `JSON.parse` meant the
|
|
215
|
+
* upgrade warning below could not fire for the population it was written for.
|
|
216
|
+
*
|
|
217
|
+
* Only comments and trailing commas are stripped, which is the whole of what
|
|
218
|
+
* wrangler accepts beyond JSON. The scan tracks string literals rather than
|
|
219
|
+
* pattern-matching, because a config carries both hazards for real: `define`
|
|
220
|
+
* holds `"\"file:///worker.js\""`, where the `//` is inside a string and the
|
|
221
|
+
* quotes around it are escaped.
|
|
222
|
+
*/
|
|
223
|
+
function parseJsonc(text) {
|
|
224
|
+
const out = [];
|
|
225
|
+
let index = 0;
|
|
226
|
+
while (index < text.length) {
|
|
227
|
+
const char = text[index];
|
|
228
|
+
if (char === "\"") {
|
|
229
|
+
const start = index;
|
|
230
|
+
index += 1;
|
|
231
|
+
while (index < text.length) {
|
|
232
|
+
if (text[index] === "\\") {
|
|
233
|
+
index += 2;
|
|
234
|
+
continue;
|
|
235
|
+
}
|
|
236
|
+
if (text[index] === "\"") {
|
|
237
|
+
index += 1;
|
|
238
|
+
break;
|
|
239
|
+
}
|
|
240
|
+
index += 1;
|
|
241
|
+
}
|
|
242
|
+
out.push(text.slice(start, index));
|
|
243
|
+
continue;
|
|
244
|
+
}
|
|
245
|
+
if (char === "/" && text[index + 1] === "/") {
|
|
246
|
+
while (index < text.length && text[index] !== "\n") index += 1;
|
|
247
|
+
continue;
|
|
248
|
+
}
|
|
249
|
+
if (char === "/" && text[index + 1] === "*") {
|
|
250
|
+
const end = text.indexOf("*/", index + 2);
|
|
251
|
+
index = end === -1 ? text.length : end + 2;
|
|
252
|
+
continue;
|
|
253
|
+
}
|
|
254
|
+
if (char === "}" || char === "]") {
|
|
255
|
+
let back = out.length - 1;
|
|
256
|
+
while (back >= 0 && /^\s+$/.test(out[back])) back -= 1;
|
|
257
|
+
if (back >= 0 && out[back] === ",") out.splice(back, 1);
|
|
258
|
+
}
|
|
259
|
+
out.push(char);
|
|
260
|
+
index += 1;
|
|
261
|
+
}
|
|
262
|
+
return JSON.parse(out.join(""));
|
|
263
|
+
}
|
|
264
|
+
/**
|
|
265
|
+
* The scaffold never overwrites an existing config, but `alias`, `define`,
|
|
266
|
+
* and `migrations_dir` are build-owned invariants pointing into the output
|
|
267
|
+
* directory — an app scaffolded before they existed deploys a worker that
|
|
268
|
+
* cannot resolve `bun:sqlite` or never applies its migrations. Name exactly
|
|
269
|
+
* what is missing rather than failing the build.
|
|
270
|
+
*
|
|
271
|
+
* Individual entries, never a whole `"alias"` or `"define"` object: apps keep
|
|
272
|
+
* their own entries under both keys — a `shiki` stub, a pinned `@guren/orm`,
|
|
273
|
+
* an extra `define` — and a suggestion shaped like a complete object reads as
|
|
274
|
+
* one to paste over what is there, which would drop them.
|
|
275
|
+
*/
|
|
276
|
+
function warnMissingBuildOwnedKeys(configPath, outRelative) {
|
|
277
|
+
let config;
|
|
278
|
+
try {
|
|
279
|
+
config = parseJsonc(readFileSync(configPath, "utf8"));
|
|
280
|
+
} catch {
|
|
281
|
+
console.warn(`Cloudflare build: could not parse ${configPath}, so its build-owned keys went unchecked. Fix the file, or compare it against a config scaffolded in an empty directory.`);
|
|
282
|
+
return;
|
|
283
|
+
}
|
|
284
|
+
const missing = [];
|
|
285
|
+
const configAlias = config.alias;
|
|
286
|
+
const alias = typeof configAlias === "object" && configAlias !== null ? configAlias : {};
|
|
287
|
+
for (const [specifier, target] of Object.entries(devOnlyAliases(outRelative))) if (!(specifier in alias)) missing.push(`${JSON.stringify(specifier)}: ${JSON.stringify(target)} (inside "alias")`);
|
|
288
|
+
if (!config.define?.["process.env.NODE_ENV"]) missing.push("\"process.env.NODE_ENV\": \"\\\"production\\\"\" (inside \"define\")");
|
|
289
|
+
const d1 = config.d1_databases?.[0];
|
|
290
|
+
if (d1 && d1.migrations_dir !== `${outRelative}/d1-migrations`) missing.push(`"migrations_dir": "${outRelative}/d1-migrations" (inside d1_databases[0])`);
|
|
291
|
+
if (missing.length > 0) console.warn(`Cloudflare build: ${configPath} predates this plugin version. Add these entries, alongside whatever the file already has under the same keys, or the worker will fail to start or skip migrations:\n ${missing.join("\n ")}`);
|
|
292
|
+
}
|
|
293
|
+
//#endregion
|
|
294
|
+
export { flattenD1Migrations as n, buildCloudflareOutput as t };
|
package/dist/commands.d.ts
CHANGED
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
//#region src/commands.d.ts
|
|
3
2
|
declare const _default: {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
3
|
+
'cloudflare:build': import("citty").CommandDef<{
|
|
4
|
+
root: {
|
|
5
|
+
type: "string";
|
|
6
|
+
description: string;
|
|
7
|
+
};
|
|
8
|
+
'skip-app-build': {
|
|
9
|
+
type: "boolean";
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
}>;
|
|
14
13
|
};
|
|
15
|
-
|
|
16
|
-
export { _default as default };
|
|
14
|
+
//#endregion
|
|
15
|
+
export { _default as default };
|
package/dist/commands.js
CHANGED
|
@@ -1,34 +1,26 @@
|
|
|
1
|
-
import {
|
|
2
|
-
buildCloudflareOutput
|
|
3
|
-
} from "./chunk-32YY6FCY.js";
|
|
4
|
-
|
|
5
|
-
// src/commands.ts
|
|
1
|
+
import { t as buildCloudflareOutput } from "./build-DxgM3l-5.js";
|
|
6
2
|
import { defineCommand } from "citty";
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
});
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
};
|
|
32
|
-
export {
|
|
33
|
-
commands_default as default
|
|
34
|
-
};
|
|
3
|
+
var commands_default = { "cloudflare:build": defineCommand({
|
|
4
|
+
meta: {
|
|
5
|
+
name: "cloudflare:build",
|
|
6
|
+
description: "Assemble a Cloudflare Workers deployment (.cloudflare/) from the app build"
|
|
7
|
+
},
|
|
8
|
+
args: {
|
|
9
|
+
root: {
|
|
10
|
+
type: "string",
|
|
11
|
+
description: "App root directory (defaults to the current working directory)"
|
|
12
|
+
},
|
|
13
|
+
"skip-app-build": {
|
|
14
|
+
type: "boolean",
|
|
15
|
+
description: "Skip running the app's build script before assembling output"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
async run({ args }) {
|
|
19
|
+
await buildCloudflareOutput({
|
|
20
|
+
rootDir: args.root || process.cwd(),
|
|
21
|
+
skipAppBuild: Boolean(args["skip-app-build"])
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
}) };
|
|
25
|
+
//#endregion
|
|
26
|
+
export { commands_default as default };
|