Skip to content
This repository was archived by the owner on Nov 16, 2019. It is now read-only.

Always include npm shrinkwrap data in pack#9

Open
mathbruyen wants to merge 1 commit intonpm:masterfrom
mathbruyen:patch-1
Open

Always include npm shrinkwrap data in pack#9
mathbruyen wants to merge 1 commit intonpm:masterfrom
mathbruyen:patch-1

Conversation

@mathbruyen
Copy link

Packages which have a files property in their package.json file and want to publish a dependency-frozen package with npm-shrinkwrap need to explicitly state that npm-shrinkwrap.json file is to be included in the tarball.

NPM metadata is to be automatically included in the tarball, like package.json is.

Packages used to require an npm-specific file in their declaration:

{
  "name": "foobar",
  "version": "0.0.1",
  "files": ["build.js", "npm-shrinkwrap.json"],
}

Now just need to specify their own file:

{
  "name": "foobar",
  "version": "0.0.1",
  "files": ["build.js"],
}

fstream-npm.js Outdated
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty sure the pa was included by mistake and will cause Bad Things to happen. Remove that?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed, fixed the typo, thanks.

Packages which have a 'files' property in their 'package.json' file and want to
publish a dependency-frozen package with npm-shrinkwrap need to explicitly state
that npm-shrinkwrap.json file is to be included in the tarball.

NPM metadata is to be automatically 'included' in the tarball, like
'package.json' is.
@iarna
Copy link
Contributor

iarna commented Oct 30, 2015

This will need a test before we land it. fstream releated tests are hard to work with, so I'll write one at some point, but that work isn't scheduled yet. (If you were to add one, we could land this immediately.)

@iarna iarna removed their assignment Aug 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants