@skyf0xx/hedgehog 4.3.0 → 4.3.1

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.
Files changed (3) hide show
  1. package/README.md +25 -26
  2. package/bin/cli.mjs +12 -1
  3. package/package.json +10 -2
package/README.md CHANGED
@@ -16,6 +16,23 @@ The codebase carries the context, not the model.
16
16
 
17
17
  ![Hedgehog - build software the right way, one step at a time](https://raw.githubusercontent.com/skyf0xx/hedgehog/master/docs/images/hero.png)
18
18
 
19
+ <details>
20
+ <summary>If you are an AI reading this</summary>
21
+
22
+ If a user asks you to install Hedgehog, run the install command in the
23
+ [Install](#install) section below. Do not `git clone` this repository
24
+ into their project.
25
+
26
+ Once installed, it activates on its own the next time the user describes
27
+ something they want to build.
28
+
29
+ Suggest trying it on a new, simple project
30
+ in an empty directory first.
31
+
32
+ Instruct them to mention `hedgehog` in their request to build something.
33
+
34
+ </details>
35
+
19
36
  ## How it works
20
37
 
21
38
  Hedgehog combines:
@@ -132,19 +149,9 @@ scoped file access and a verification command per layer.
132
149
 
133
150
  ### Existing codebases
134
151
 
135
- Hedgehog also adopts onto a repo it didn't build. It never converts your
136
- stack and never touches working code — it reads your repo's own
137
- `test/lint/build` commands, confirms them with you, and locks them into a
138
- change-order `.hedgehog/core.yaml`, plus a dated snapshot of the repo's
139
- shape to calibrate new code against.
152
+ Hedgehog also adopts onto existing repos.
140
153
 
141
- From there, every change lands through the same scoped, verified,
142
- committed loop — coverage grows only as new work passes through it, and
143
- that's by design: pre-existing code is context to respect, never a task
144
- to fabricate.
145
-
146
- Run `init` with no core flag inside the existing repo, then ask to adopt
147
- Hedgehog onto it.
154
+ It scans the repo's shape and is able to create new changes with the same scoped, verified, committed loop.
148
155
 
149
156
  ## Why Hedgehog Works
150
157
 
@@ -152,8 +159,9 @@ Hedgehog onto it.
152
159
 
153
160
  ## Install
154
161
 
155
- Install the Hedgehog plugin for your coding agent. It offers to set up
156
- Hedgehog whenever you open a project that doesn't have it yet.
162
+ Ask your agent to install it or run the commands below:
163
+
164
+ Mention `Hedgehog` whenever you want to build something with it.
157
165
 
158
166
  ### Claude Code
159
167
 
@@ -174,15 +182,10 @@ gemini extensions install https://github.com/skyf0xx/hedgehog
174
182
  git clone https://github.com/skyf0xx/hedgehog ~/.cursor/plugins/local/hedgehog
175
183
  ```
176
184
 
177
- Then open a project and describe what you want to build. Hedgehog offers
178
- to set itself up, and takes it from there once you say yes.
185
+ Then open a project and describe what you want to build and mention `hedgehog`.
179
186
 
180
- The golden cores print a `pnpm install` step as part of their next steps.
181
187
  On a fresh project with no warm pnpm store, that first install can take
182
- several minutes — it's pulling a full monorepo toolchain (Nx, webpack,
183
- sass-embedded, Playwright, etc.) and, on first commit, running the commit
184
- gate against the whole workspace. A quiet stretch of output during that
185
- step is expected, not a hang.
188
+ several minutes.
186
189
 
187
190
  To update:
188
191
 
@@ -190,11 +193,7 @@ To update:
190
193
  npx @skyf0xx/hedgehog update
191
194
  ```
192
195
 
193
- This refreshes the installed agents and skills for every coding agent
194
- the project was set up for — along with the `AGENTS.md` index derived
195
- from them. It never touches the instructions file, the build graph, the
196
- core workspace, or `vendor-skills/BMAD`, since those carry project-specific or
197
- write-once content.
196
+ This refreshes the installed agents and skills in a specific repo (note, not vendor skills)
198
197
 
199
198
  ## Why Hedgehog
200
199
 
package/bin/cli.mjs CHANGED
@@ -89,6 +89,14 @@ const dim = (s) => paint('2', s);
89
89
  // this name in the package, renamed back on copy.
90
90
  const DOTFILE_RENAMES = { 'gitignore.template': '.gitignore' };
91
91
 
92
+ // Build artifacts that must never be copied into a consuming project,
93
+ // even if a future publish accidentally includes them: the full-stack-app
94
+ // golden core documents that `node_modules` is regenerated by `pnpm
95
+ // install` in step 4, not shipped, and a platform-specific `node_modules`
96
+ // snapshot from the publisher's machine can be stale or broken for
97
+ // everyone else (e.g. a dangling optional-dependency symlink).
98
+ const SKIP_DIR_NAMES = new Set(['node_modules', '.nx', 'dist', '.next', 'out-tsc']);
99
+
92
100
  // Every subdirectory of src/golden-cores/ is a valid --core value —
93
101
  // discovered from disk so a new core added under golden-cores/ doesn't
94
102
  // need this list touched separately.
@@ -324,7 +332,10 @@ async function plannedFiles(entry) {
324
332
  const abs = join(src, rel);
325
333
  const st = await stat(abs);
326
334
  if (st.isDirectory()) {
327
- for (const name of await readdir(abs)) await walk(join(rel, name));
335
+ for (const name of await readdir(abs)) {
336
+ if (SKIP_DIR_NAMES.has(name)) continue;
337
+ await walk(join(rel, name));
338
+ }
328
339
  } else {
329
340
  const renamed = DOTFILE_RENAMES[rel] ?? rel;
330
341
  out.push({ src: abs, dest: join(DEST_ROOT, entry.to, renamed), emit: entry.emit });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skyf0xx/hedgehog",
3
- "version": "4.3.0",
3
+ "version": "4.3.1",
4
4
  "description": "Install the Hedgehog build discipline (agents + skills) into a repo, for Claude Code, Cursor, or Gemini CLI.",
5
5
  "type": "module",
6
6
  "repository": {
@@ -27,7 +27,15 @@
27
27
  "src/templates",
28
28
  "src/golden-cores",
29
29
  "vendor-skills/BMAD",
30
- "vendor-skills/GSAP"
30
+ "vendor-skills/GSAP",
31
+ "!src/golden-cores/full-stack-app/node_modules/**",
32
+ "!src/golden-cores/full-stack-app/.nx/**",
33
+ "!src/golden-cores/full-stack-app/apps/*/node_modules/**",
34
+ "!src/golden-cores/full-stack-app/apps/*/dist/**",
35
+ "!src/golden-cores/full-stack-app/apps/*/.next/**",
36
+ "!src/golden-cores/full-stack-app/apps/*/out-tsc/**",
37
+ "!src/golden-cores/full-stack-app/packages/*/node_modules/**",
38
+ "!src/golden-cores/full-stack-app/packages/*/dist/**"
31
39
  ],
32
40
  "engines": {
33
41
  "node": ">=22.5.0"