When I run npm pack
it produces a .tgz
with all the contents inside of ./package/
. Is the behavior of npm pack
specified anywhere?
Asked
Active
Viewed 145 times
0

Evan Carroll
- 78,363
- 46
- 261
- 468
-
https://docs.npmjs.com/cli/v6/commands/npm-pack? – paolostyle Oct 06 '21 at 21:02
-
What do you mean by behaviour? If you mean how should the directory for thé resultant `.tgz` be structured, then it’s worth noting that NPM expects the root directory in thé tarball (`.tgz`) to be named `package` - see [this post](https://stackoverflow.com/questions/62692052/npmjs-org-unable-to-find-a-readme-for/62694753#62694753) – RobC Oct 07 '21 at 08:37
-
@paolostyle that doesn't say anything about the directory structure, at all. – Evan Carroll Oct 07 '21 at 13:39
-
@RobC that does hit on what I'm talking about but only insofar as it infers it the same way I'm inferring it. I'll update the example for more about what I'm looking for. – Evan Carroll Oct 07 '21 at 13:41