Makes npm installs fast, resilient, and reproducible by caching dependencies locally.
Shrinkpack is a Node.js tool that caches npm package tarballs locally, allowing for offline and resilient dependency installations. It solves the problem of builds failing due to npm registry outages or removed packages by storing dependencies in your project's source control. It modifies the package-lock.json to point to these local copies, ensuring reproducible builds.
Developers and teams using npm in CI/CD pipelines or environments where network reliability is a concern, and those who prioritize reproducible builds and offline capability.
Developers choose Shrinkpack because it guarantees build reproducibility and resilience without the drawbacks of checking in the entire node_modules directory. It provides a lightweight, cross-platform solution to dependency management that works seamlessly with npm's existing lockfile system.
Fast, resilient, reproducible builds with npm install.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Enables completely offline dependency installation using `npm ci --offline`, as highlighted in the README, protecting builds from npm registry outages like the left-pad incident.
Stores exact dependency tarballs locally, ensuring the same versions are installed every time, which mitigates risks from lockfile mutations in nested dependencies.
Decompresses .tgz files into .tar files to avoid binary files in Git and reduce decompression overhead during install, as specified in the README.
Avoids OS-specific binary issues (e.g., with phantomjs) by storing platform-agnostic tarballs, unlike checking in the entire node_modules directory.
Requires npm@7 or higher, as stated in the Installation section, which can hinder adoption in legacy projects or environments with older npm versions.
Development was abandoned for years due to npm regressions (see History section), raising doubts about future updates and bug fixes.
Adds the `node_shrinkpack` directory with tarballs to source control, increasing repository size and potentially slowing Git operations.