Files
btc69m979y-dotcom 305c13d3f5 fix: Windows 平台 electron-builder 打包 asar 缺失 dist 目录
将 electron-builder.json 中 files 配置从 glob 字符串改为对象格式,
使用 from/to/filter 明确指定 dist 和 dist-electron 目录。

glob 字符串格式 ("dist/**/*") 在 Windows 上由于路径分隔符差异,
minimatch partial matching 无法正确识别目录,导致 dist/ 和
dist-electron/ 未被打包进 asar,构建失败。

同时添加 .npmignore 确保 electron-builder 不会因 .gitignore 排除
构建产物目录。
2026-03-02 15:19:55 +08:00

45 lines
817 B
Plaintext

# .npmignore - Used by electron-builder instead of .gitignore
# This file intentionally does NOT exclude dist/ and dist-electron/
# so that build outputs are included in the asar archive.
src/
tests/
scripts/
build/*
!build/entitlements.mac.plist
!build/icons/
!build/icons/**
release/
.DS_Store
.env
.claude/
__pycache__/
.codebuddy/
sandbox/image/out/
sandbox/image/publish/
sandbox/image/.work/
sandbox/runtime/out/
sandbox/runtime-darwin-*/
resources/mingit/
resources/MinGit-*.zip
resources/PortableGit-*.7z.exe
resources/python-win/
resources/python-*.zip
SKILLs/**/.connection
SKILLs/**/.server.log
SKILLs/**/.server.pid
SKILLs/**/.venv/
nul
.work.env
.playwright-mcp/
.cowork-temp/
*.ts
!*.d.ts
tsconfig.json
electron-tsconfig.json
vite.config.ts
tailwind.config.js
postcss.config.js
.eslintrc.cjs
CLAUDE.md