@solcreek/cli 0.4.25 → 0.4.26
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/utils/nextjs.js +12 -6
- package/package.json +1 -1
package/dist/utils/nextjs.js
CHANGED
|
@@ -179,11 +179,13 @@ const CREEK_DIR = ".creek";
|
|
|
179
179
|
const OPENNEXT_PKG = "@opennextjs/cloudflare";
|
|
180
180
|
const OPENNEXT_VERSION = "^1.18.0";
|
|
181
181
|
const ADAPTER_PKG = "@solcreek/adapter-creek";
|
|
182
|
-
const ADAPTER_VERSION = "^0.2.
|
|
183
|
-
// Adapter < 0.2.
|
|
184
|
-
// under the .creek lazy install
|
|
185
|
-
//
|
|
186
|
-
|
|
182
|
+
const ADAPTER_VERSION = "^0.2.2";
|
|
183
|
+
// Adapter < 0.2.2 resolves its dependencies against paths that don't exist
|
|
184
|
+
// under the .creek lazy install (0.2.0: the cache handler; 0.2.1: the
|
|
185
|
+
// wrangler bin) — npm hoists them to the top of the tree, so the adapter's
|
|
186
|
+
// guessed nested paths fail every Next.js build. Installs below this are
|
|
187
|
+
// re-installed, not reused.
|
|
188
|
+
const ADAPTER_MIN_VERSION = "0.2.2";
|
|
187
189
|
/**
|
|
188
190
|
* Merge a dependency into .creek/package.json without clobbering deps that
|
|
189
191
|
* a previous install (adapter or opennext) may have already written.
|
|
@@ -213,7 +215,11 @@ function installCreekDep(creekDir, pkg, version) {
|
|
|
213
215
|
mkdirSync(creekDir, { recursive: true });
|
|
214
216
|
upsertCreekDep(creekDir, pkg, version);
|
|
215
217
|
try {
|
|
216
|
-
|
|
218
|
+
// No --no-optional: the adapter bundles the worker with wrangler, whose
|
|
219
|
+
// workerd dependency ships its platform binary (@cloudflare/workerd-*)
|
|
220
|
+
// as an optionalDependency. Omitting optionals fails the build with
|
|
221
|
+
// "package could not be found, and is needed by workerd".
|
|
222
|
+
execSync("npm install --no-audit --no-fund --ignore-scripts", {
|
|
217
223
|
cwd: creekDir,
|
|
218
224
|
stdio: "pipe",
|
|
219
225
|
});
|