npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@hy-sde-org/dsh-fs-archive

v0.2.0-rc.2

Published

Pure-TS multi-format archive engine (zip/tar/tar.gz/rar/7z/iso/deb/rpm/cpio/cab/arj/asar + codecs), ported from @oh-my-pi/pi-utils (MIT), as a standalone npm package.

Readme

@hy-sde-org/dsh-fs-archive

A pure-TS multi-format archive engine — zip, tar, tar.gz, rar, 7z, iso, deb, rpm, cpio, cab, arj, asar — plus the codec layer (gzip, bzip2, ncompress LZW, xz, deflate, zstd) behind them. Ported from @oh-my-pi/pi-utils.

This is the durable core of the harness read tool's multi-format support: foo.zip lists an archive's root, foo.zip:dir lists a directory, and foo.zip:dir/file.txt reads one member as text. Published standalone as @hy-sde-org/dsh-fs-archive; it mirrors @deepseek-ai/dsh-fs-archive in the hy-sde deepseek-harness fork.

Format detection sniffs content signatures (sniffArchiveFormat) and falls back to extension inference (archiveFormatFromPath); member reads are bounded by ArchiveLimits (entry count, index size, in-memory size, member size, path bytes, link depth) so attacker-controlled archives cannot drive unbounded allocation.

Port differences

  • No Bun runtime: Bun.hash.crc32 is table-driven CRC-32, Bun.CryptoHasher is node:crypto SHA-256, and Bun.file / Bun.write are node:fs / node:fs/promises equivalents.
  • All relative imports carry the .ts extension (repo rewriteRelativeImportExtensions).
  • formatBytes, the small LRUCache, and the public index.ts surface replace the upstream package-level re-exports; tests load fixtures from one bundled tar.gz (the same layout upstream uses to keep checkout state quiet).
  • The optional ./invariant companion registers the package into a Cordis host's ctx.invariants service (no-op); it needs @deepseek-ai/cordis + @deepseek-ai/dsh-invariants peers only when you use that entry.

Otherwise the port is algorithmically 1:1 with the original source. Keep the two sources in sync when the fork backports upstream archive-engine fixes.

Known Limitations and Deferred Work

  • The harness read tool member reads go through ctx.fs.readBytes with a bounded readMaxArchiveBytes (default 256 MiB): the archive file is loaded into memory for indexing. No streaming/local fileByteSource path is wired into the tool yet, so very large archives stay beyond the cap even though the engine itself supports lazy source reads.
  • The harness read tool serves member text and listings only; archive writing is not exposed through the tool (members are immutable there), though this package's writeArchive API supports zip/tar/tar.gz/asar writing for programmatic use.
  • Detection needs either content sniffing or an archive extension on the path; a member named with a supported archive extension inside a container is interpreted by longest-prefix rules from parseArchivePathCandidates.

Package API:

import {
  openArchive,
  parseArchivePathCandidates,
  sniffArchiveFormat,
  formatArchiveEntryLines,
} from '@hy-sde-org/dsh-fs-archive'
  • openArchive(source, options) — open a file path or { bytes, format } into an ArchiveReader; getNode resolves members, listDirectory lists, readFile reads one member's bytes, indexEntries enumerates.
  • parseArchivePathCandidates(filePath) — split archive.ext:member/path into resolution candidates (longest archive prefix first).
  • sniffArchiveFormat(bytes) / archiveFormatFromPath(path) — format rules.
  • formatArchiveEntryLines(entries) — one line per member, name/ for directories and name (size) for files.
  • See src/index.ts for the full export surface.

License

Port of MIT-licensed code. Original copyright: Copyright (c) 2025-2026 Can Bölük and contributors. Derived files carry header attribution; see the inline file headers and THIRD-PARTY-NOTICES.md.