create-nextly-app 0.0.2-alpha.23 → 0.0.2-alpha.25
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/{chunk-6HFD2Q2U.mjs → chunk-XMNVVIVZ.mjs} +33 -10
- package/dist/chunk-XMNVVIVZ.mjs.map +1 -0
- package/dist/cli.cjs +32 -9
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.mjs +2 -2
- package/dist/cli.mjs.map +1 -1
- package/dist/index.cjs +31 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/chunk-6HFD2Q2U.mjs.map +0 -1
|
@@ -25070,10 +25070,6 @@ async function generatePackageJson(projectName, database, useYalc = false, proje
|
|
|
25070
25070
|
// don't ship a /search page simply won't invoke it.
|
|
25071
25071
|
pagefind: "^1.1.0"
|
|
25072
25072
|
};
|
|
25073
|
-
const onlyBuiltDependencies = ["sharp", "esbuild", "unrs-resolver"];
|
|
25074
|
-
if (database.type === "sqlite") {
|
|
25075
|
-
onlyBuiltDependencies.push("better-sqlite3");
|
|
25076
|
-
}
|
|
25077
25073
|
const pkg = {
|
|
25078
25074
|
name: projectName,
|
|
25079
25075
|
version: "0.1.0",
|
|
@@ -25104,13 +25100,35 @@ async function generatePackageJson(projectName, database, useYalc = false, proje
|
|
|
25104
25100
|
"types:generate": "nextly generate:types"
|
|
25105
25101
|
},
|
|
25106
25102
|
dependencies,
|
|
25107
|
-
devDependencies
|
|
25108
|
-
pnpm: {
|
|
25109
|
-
onlyBuiltDependencies
|
|
25110
|
-
}
|
|
25103
|
+
devDependencies
|
|
25111
25104
|
};
|
|
25112
25105
|
return JSON.stringify(pkg, null, 2) + "\n";
|
|
25113
25106
|
}
|
|
25107
|
+
var NATIVE_BUILD_DEPENDENCIES = [
|
|
25108
|
+
"better-sqlite3",
|
|
25109
|
+
"esbuild",
|
|
25110
|
+
"sharp",
|
|
25111
|
+
"unrs-resolver"
|
|
25112
|
+
];
|
|
25113
|
+
function generatePnpmWorkspaceYaml() {
|
|
25114
|
+
const allowBuilds = NATIVE_BUILD_DEPENDENCIES.map(
|
|
25115
|
+
(dep) => ` ${dep}: true`
|
|
25116
|
+
).join("\n");
|
|
25117
|
+
const onlyBuilt = NATIVE_BUILD_DEPENDENCIES.map((dep) => ` - ${dep}`).join(
|
|
25118
|
+
"\n"
|
|
25119
|
+
);
|
|
25120
|
+
return `# Allow native dependencies to run their build scripts. pnpm 10+ blocks
|
|
25121
|
+
# dependency build scripts by default; without this better-sqlite3 has no
|
|
25122
|
+
# compiled binding (sqlite apps crash at boot) and sharp/esbuild degrade.
|
|
25123
|
+
#
|
|
25124
|
+
# pnpm 11+ reads \`allowBuilds\`; pnpm 10.6+ reads \`onlyBuiltDependencies\`.
|
|
25125
|
+
# npm, yarn, and pnpm 9 ignore this file (they run build scripts by default).
|
|
25126
|
+
allowBuilds:
|
|
25127
|
+
${allowBuilds}
|
|
25128
|
+
onlyBuiltDependencies:
|
|
25129
|
+
${onlyBuilt}
|
|
25130
|
+
`;
|
|
25131
|
+
}
|
|
25114
25132
|
async function copyTemplate(options) {
|
|
25115
25133
|
const {
|
|
25116
25134
|
projectName,
|
|
@@ -25210,6 +25228,11 @@ async function copyTemplate(options) {
|
|
|
25210
25228
|
packageJsonContent,
|
|
25211
25229
|
"utf-8"
|
|
25212
25230
|
);
|
|
25231
|
+
await import_fs_extra8.default.writeFile(
|
|
25232
|
+
path.join(targetDir, "pnpm-workspace.yaml"),
|
|
25233
|
+
generatePnpmWorkspaceYaml(),
|
|
25234
|
+
"utf-8"
|
|
25235
|
+
);
|
|
25213
25236
|
if (database.type === "sqlite") {
|
|
25214
25237
|
await import_fs_extra8.default.ensureDir(path.join(targetDir, "data"));
|
|
25215
25238
|
}
|
|
@@ -28865,5 +28888,5 @@ async function createNextly(options = {}) {
|
|
|
28865
28888
|
*/
|
|
28866
28889
|
|
|
28867
28890
|
export { __commonJS, __require, __toESM, capture, createNextly, init, resolveProjectArg, shutdown, validateProjectName };
|
|
28868
|
-
//# sourceMappingURL=chunk-
|
|
28869
|
-
//# sourceMappingURL=chunk-
|
|
28891
|
+
//# sourceMappingURL=chunk-XMNVVIVZ.mjs.map
|
|
28892
|
+
//# sourceMappingURL=chunk-XMNVVIVZ.mjs.map
|