Skip to content

build(zip): 源码包排除私有文档仓库 notes/ 与链接进来的 CONTEXT.md —— 文档移到私有仓库后 wxt 打源码包不看 .gitignore,会把它们一起打进去 - #1171

Merged
Teeeeeeeerry merged 1 commit into
mainfrom
build/zip-exclude-private-docs
Oct 27, 2026
Merged

Teeeeeeeerry merged 1 commit into
mainfrom
build/zip-exclude-private-docs

Conversation

@Teeeeeeeerry

Copy link
Copy Markdown
Owner

问题

为 2.1.243 打包时发现,pnpm zip:firefox 生成的源码包(发到 Releases、给 AMO 审核用)里带上了私有文档仓库:notes/ 整个目录(术语表、ADR、测试体系说明、上架材料等约 100 个文件)和根目录的 CONTEXT.md。

根因

#1109 把内部文档移到私有仓库,克隆在 notes/,并在原位置建了指向它的本地链接;这些路径只加进了 .gitignore。wxt 打源码包不看 .gitignore,只按 zip.excludeSources 排除,原来的列表只有 docs/**、store/**、design/**,所以 notes/ 与 CONTEXT.md 被打了进去。2.1.218 发版时文档还在公开仓库,那次的源码包没有这个问题。

修复

  • wxt.config.ts:excludeSources 加上 notes/** 与 CONTEXT.md(其余链接都在 docs/、store/ 下,已被排除)。
  • 版本号不动:这是打包配置,2.1.243 的更新提示条目已经合并,版本号要与它保持一致。

验证

  • 重新打包后源码包 173 个文件,与 2.1.218 的源码包相比只多了这期间新增的源码文件(src/、entrypoints/),少了已移走的 CONTEXT.md;不含 notes/。

@Teeeeeeeerry
Teeeeeeeerry merged commit 23222d4 into main Oct 27, 2026
7 checks passed
@Teeeeeeeerry
Teeeeeeeerry deleted the build/zip-exclude-private-docs branch October 27, 2026 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant