@skyf0xx/hedgehog 0.1.9 → 0.1.11
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/bin/cli.mjs +9 -1
- package/package.json +1 -1
- package/src/golden-core/gitignore.template +20 -0
- package/src/templates/CLAUDE.md +10 -0
package/bin/cli.mjs
CHANGED
|
@@ -25,6 +25,13 @@ const yellow = (s) => paint('33', s);
|
|
|
25
25
|
const red = (s) => paint('31', s);
|
|
26
26
|
const dim = (s) => paint('2', s);
|
|
27
27
|
|
|
28
|
+
// npm's publish step silently drops any file literally named `.gitignore`
|
|
29
|
+
// (also `.npmignore`, `.git`, etc.) from the tarball, even when the
|
|
30
|
+
// containing directory is listed in `files` — there's no way to opt back
|
|
31
|
+
// in via `files` or `.npmignore`. So golden-core's is stored under this
|
|
32
|
+
// name and renamed back to `.gitignore` on copy, per dir entry below.
|
|
33
|
+
const DOTFILE_RENAMES = { 'gitignore.template': '.gitignore' };
|
|
34
|
+
|
|
28
35
|
// ── the payload: what gets copied, and to where under the target repo ───
|
|
29
36
|
// `dir` entries copy a whole tree; `file` entries copy a single file and
|
|
30
37
|
// may rename (templates lose their src/templates/ prefix at the root).
|
|
@@ -61,7 +68,8 @@ async function plannedFiles(entry) {
|
|
|
61
68
|
if (st.isDirectory()) {
|
|
62
69
|
for (const name of await readdir(abs)) await walk(join(rel, name));
|
|
63
70
|
} else {
|
|
64
|
-
|
|
71
|
+
const renamed = DOTFILE_RENAMES[rel] ?? rel;
|
|
72
|
+
out.push({ src: abs, dest: join(DEST_ROOT, entry.to, renamed) });
|
|
65
73
|
}
|
|
66
74
|
}
|
|
67
75
|
await walk('.');
|
package/package.json
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
node_modules
|
|
2
|
+
dist
|
|
3
|
+
tmp
|
|
4
|
+
out-tsc
|
|
5
|
+
.env
|
|
6
|
+
.env.local
|
|
7
|
+
*.log
|
|
8
|
+
.DS_Store
|
|
9
|
+
|
|
10
|
+
.nx/cache
|
|
11
|
+
.nx/workspace-data
|
|
12
|
+
.nx/polygraph
|
|
13
|
+
.claude/worktrees
|
|
14
|
+
.claude/settings.local.json
|
|
15
|
+
vitest.config.*.timestamp*
|
|
16
|
+
|
|
17
|
+
# Next.js
|
|
18
|
+
.next
|
|
19
|
+
out
|
|
20
|
+
test-output
|
package/src/templates/CLAUDE.md
CHANGED
|
@@ -20,6 +20,16 @@ This project is built with **Hedgehog**: a backend-first, one-step-at-a-time
|
|
|
20
20
|
build discipline. The rules below aren't project preferences — they're how
|
|
21
21
|
the build stays mechanically correct. Follow them exactly.
|
|
22
22
|
|
|
23
|
+
## First message in a fresh install
|
|
24
|
+
|
|
25
|
+
If `{{PROJECT_SUMMARY}}` above is still an unfilled placeholder, this is a
|
|
26
|
+
brand-new install and nothing has been built yet. Open with something
|
|
27
|
+
short and warm — 🦔 plus one line asking what the user wants to build —
|
|
28
|
+
then hand straight to `planner` to run Intake. Don't re-explain the
|
|
29
|
+
discipline or summarize this file; the greeting is one line, not a tour.
|
|
30
|
+
Skip this entirely once the placeholder is filled in — every later session
|
|
31
|
+
starts with `TODO.md`, not a greeting.
|
|
32
|
+
|
|
23
33
|
## How to work here
|
|
24
34
|
|
|
25
35
|
The build is a loop of small, gated, committed steps. You never hold the
|