Commit 509c0be
fix(packaging): keep bundled node_modules/npm in win32-x64 .vsix + add CI verify
User reported v0.1.1 .vsix with bundled Node + npm.cmd STILL failed
when enabling search mode:
Error: Cannot find module
'...\node-runtime\node_modules\npm\bin\npm-cli.js'
MODULE_NOT_FOUND
Root cause: `.vscodeignore` had `**/node_modules/**` which matches
EVERY `node_modules/` at any depth — including the bundled
`extension/bin/node-runtime/node_modules/npm/` that we explicitly
extracted from the Node Windows zip during CI. So vsce dropped the
entire npm package while keeping node.exe + npm.cmd, leaving a
"bundled Node" install that couldn't actually run npm.
This is the third Windows fix attempt for search-mode. Each
previous one was structurally correct but a layer-below bug
silently sabotaged it. To stop the cycle, this commit also adds a
CI verification step that fails the build if the required files
aren't physically inside the .vsix.
Files:
- extension/.vscodeignore — replaced `**/node_modules/**` (matches
any depth) with `node_modules/**` (only the top-level
extension/node_modules). The bundled
bin/node-runtime/node_modules/ now ships intact.
- .github/workflows/publish-extension.yml — new "Verify bundled
Node runtime" step on win32-x64. Lists the .vsix via `unzip -l`
and asserts each of these is present:
extension/bin/axme-code.exe
extension/bin/node-runtime/node.exe
extension/bin/node-runtime/npm.cmd
extension/bin/node-runtime/node_modules/npm/bin/npm-cli.js
extension/bin/node-runtime/node_modules/npm/bin/npm-prefix.js
Any missing entry fails the build with a clear ::error:: marker.
If a future .vscodeignore tweak or vsce update silently drops one
of these, CI will catch it BEFORE we ship a broken .vsix to
users. Caught the original regression manually on 2026-05-19 —
never again.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 33e396d commit 509c0be
2 files changed
Lines changed: 38 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
204 | 204 | | |
205 | 205 | | |
206 | 206 | | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
207 | 238 | | |
208 | 239 | | |
209 | 240 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
13 | 19 | | |
14 | 20 | | |
15 | 21 | | |
0 commit comments