nerdsystem 0.0.16 → 0.0.17
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/init.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { execFileSync } from "node:child_process";
|
|
2
|
-
import { cpSync, existsSync, mkdirSync, readdirSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
2
|
+
import { cpSync, existsSync, mkdirSync, readdirSync, readFileSync, renameSync, rmSync, writeFileSync } from "node:fs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { fileURLToPath } from "node:url";
|
|
5
5
|
import { ApiClient } from "../api.js";
|
|
@@ -144,6 +144,15 @@ export async function init(dir, args) {
|
|
|
144
144
|
// The published template carries ".gitignore" as "gitignore" (npm strips the dotted name from packages).
|
|
145
145
|
if (existsSync(path.join(root, "gitignore")) && !existsSync(path.join(root, ".gitignore")))
|
|
146
146
|
renameSync(path.join(root, "gitignore"), path.join(root, ".gitignore"));
|
|
147
|
+
// pnpm 11 and later read build approvals from pnpm-workspace.yaml (the package.json key is for pnpm 10) and
|
|
148
|
+
// fail the install without them. The template keeps the file under another name because a real
|
|
149
|
+
// pnpm-workspace.yaml inside packages/template would make it a workspace root within this repository.
|
|
150
|
+
if (existsSync(path.join(root, "pnpm-workspace.app.yaml"))) {
|
|
151
|
+
if (existsSync(path.join(root, "pnpm-workspace.yaml")))
|
|
152
|
+
rmSync(path.join(root, "pnpm-workspace.app.yaml"));
|
|
153
|
+
else
|
|
154
|
+
renameSync(path.join(root, "pnpm-workspace.app.yaml"), path.join(root, "pnpm-workspace.yaml"));
|
|
155
|
+
}
|
|
147
156
|
const description = args.describe ?? (await askDescription());
|
|
148
157
|
// Rename the app and point the SDK dependency somewhere installable.
|
|
149
158
|
const pkgPath = path.join(root, "package.json");
|
|
@@ -183,4 +192,4 @@ export async function init(dir, args) {
|
|
|
183
192
|
log.ok(`Ready. Next:\n cd ${dir}\n pnpm install\n nerd dev\n\nThen open the folder in your coding agent and ask it to build the first feature; the nerdsystem skill walks it through.\nDeploys go to ${project.url}`);
|
|
184
193
|
}
|
|
185
194
|
// Kept in sync with packages/sdk/package.json by the release script.
|
|
186
|
-
const SDK_VERSION = "0.0.
|
|
195
|
+
const SDK_VERSION = "0.0.17";
|
package/package.json
CHANGED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# Settings for pnpm 11 and later, which read them here and not from package.json.
|
|
2
|
+
# The two packages below ship a program that has to be set up on install; pnpm asks before running such steps.
|
|
3
|
+
allowBuilds:
|
|
4
|
+
esbuild: true
|
|
5
|
+
workerd: true
|
|
6
|
+
# nerdsystem's own library is used on the day it is released; other packages keep pnpm's waiting period.
|
|
7
|
+
minimumReleaseAgeExclude:
|
|
8
|
+
- '@nerdsystem/sdk'
|