@ai-ecoverse/wasm-zip

中文文档
3.0.0-11发布于 2026/10/22Info-ZIP零依赖构建来源已验证近 30 天下载 2139

zip, unzip and zipinfo (Info-ZIP), to make, list, test and extract .zip archives.

原始使用文档

@ai-ecoverse/wasm-zip

Info-ZIP zip 3.0 and unzip 6.0 for slicc's wasm realm.

pnpm add -g @ai-ecoverse/wasm-zip
zip out.zip file.txt
unzip -l out.zip
  • zip -T runs unzip itself, without a shell. A -TT command is a shell command, so it needs one (@ai-ecoverse/wasm-bash).
  • Non-ASCII names are UTF-8. zip sets the UTF-8 flag on them, and unzip shows them and reads Info-ZIP's Unicode path field.
  • The realm's file names are UTF-8. An entry whose name isn't (an old Latin-1 or CP437 archive without a Unicode path) is not extracted under a changed name: unzip says cannot create <name> / Illegal byte sequence and exits 50. unzip -p still streams its bytes. Such entries are refused rather than renamed because a substituted name can collide with another entry or an existing file and silently overwrite it.
  • unzip -% (opt-in) extracts those entries under an escaped name instead. Each byte of the name outside a valid UTF-8 sequence becomes %XX (two upper-case hex digits), and a % in that name becomes %25; a name that is valid UTF-8 is left exactly as it is. So caf\xe9.txt is written as caf%E9.txt and 100%\xe9.txt as 100%25%E9.txt, and unzip prints escaped: <path> for each one. To get the stored name back, replace every %XX in a reported path with the byte XX, e.g. in Python urllib.parse.unquote_to_bytes(name). An escaped name never replaces anything: if its path exists already (on disk, or from an earlier entry), the entry is refused by name, and a later entry whose path an escaped entry took is refused too. unzip then exits 2, also under -o and -n. Symlink targets are not escaped, so a link whose target isn't UTF-8 is still refused.
  • A Unix entry with the PKWARE verification bit (internal attribute bit 2) carries a checksum where its mode would be, so it is extracted as a regular file with 0666 (0444 if marked read-only) less your umask, not with the mode 000 that Debian's handling of the bit leaves.
  • zip - … > file and zip - … | … write valid archives, and zip -s 0 merges split archives (zip -s 1m) back with every byte.
  • zipinfo is unzip's zipinfo mode, the same as unzip -Z.
  • unzip carries Debian's unzip 6.0 security patches.

版本与发布记录

@ai-ecoverse/wasm-zip 共发布 12 个版本,首次发布于 2026/09/28;过去 12 个月发布了 12 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
3.0.0-11latest2026/10/2216 天前
3.0.0-102026/10/2217 天前
3.0.0-92026/10/2018 天前
3.0.0-82026/10/2018 天前
3.0.0-72026/10/1920 天前
3.0.0-62026/10/1920 天前

关于 @ai-ecoverse/wasm-zip 的常见问题

@ai-ecoverse/wasm-zip 是什么?

zip, unzip and zipinfo (Info-ZIP), to make, list, test and extract .zip archives.

如何安装 @ai-ecoverse/wasm-zip?

在项目目录运行 npm install @ai-ecoverse/wasm-zip,或使用 pnpm add / yarn add / bun add。

@ai-ecoverse/wasm-zip 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/ai-ecoverse__wasm-zip 是否存在。

@ai-ecoverse/wasm-zip 可以商用吗?

@ai-ecoverse/wasm-zip 使用 Info-ZIP 许可。声明的许可为 Info-ZIP,请阅读许可原文确认使用条件。以上为概括,不构成法律意见,请以许可原文为准。

@ai-ecoverse/wasm-zip 的下载量有多少?

根据 npm 官方下载统计,@ai-ecoverse/wasm-zip 在 2026/10/05 – 2026/11/03 这 30 天内被下载 2,139 次,日均约 71 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@ai-ecoverse/wasm-zip 还在维护吗?

最新版本 3.0.0-11 发布于 2026/10/22(16 天前);至今共发布 12 个版本,其中过去 12 个月发布了 12 个;首次发布于 2026/09/28。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。