2 ms·
I know that npm now has a per-user cache in ~/.npm: https://docs.npmjs.com/cli/v7/commands/npm-cache https://docs.npmjs.com/cli/v7/commands/npm-cache I am not
by bhouston 2y ago
I know that npm now has a per-user cache in ~/.npm:
https://docs.npmjs.com/cli/v7/commands/npm-cache https://docs.npmjs.com/cli/v7/commands/npm-cache
I am not sure if it uses CoW to bring those packages into each project. If it did, that would be efficient and speed up "npm install" if the cache was warm.
- derefr 2y agoLanguage package managers don't need copy-on-write, because there's no "write" — the files that make up dependencies are immutable from the perspective of the projects that they get installed into. There's no advantage to using CoW to "deploy" such files into work trees, over using plain-old hard links to do so. (And hard-linking these files is indeed what all the Node package managers — other than NPM — already do.)
- styfle 2y agoNot npm but it’s used by pnpm for awhile. https://github.com/pnpm/pnpm/issues/1505 https://github.com/pnpm/pnpm/issues/1505