Commit 6cd3cd0
Support *all* conf keys in publishConfig
This adds a flatOptions.flatten() method, which takes an object full of
config keys, and turns it into an options object. This method expects
an object that already inherits from npm's defaults, and is thus
expected to be internal only.
This commit also removes some config keys which were used by npm
dependencies at the start of the v7 beta process, but are no longer:
- all lockfile configs (since we don't use lockfiles any more! for
anything! and good riddance, they're a rats' nest of race conditions)
- cacheMax/cacheMin (we only use preferOffline/offline/online now, so
these are strictly legacy support as input and never shared with deps)
Once this lands in cli, we can remove the publishConfig handling logic
in npm-registry-fetch, as it will be redundant.1 parent 48ee8d0 commit 6cd3cd0
5 files changed
Lines changed: 306 additions & 231 deletions
File tree
- lib
- utils
- tap-snapshots
- test/lib
- utils
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
15 | 18 | | |
16 | 19 | | |
17 | 20 | | |
| |||
46 | 49 | | |
47 | 50 | | |
48 | 51 | | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
49 | 62 | | |
50 | 63 | | |
51 | | - | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
52 | 68 | | |
53 | 69 | | |
54 | 70 | | |
| |||
58 | 74 | | |
59 | 75 | | |
60 | 76 | | |
61 | | - | |
| 77 | + | |
62 | 78 | | |
63 | 79 | | |
64 | 80 | | |
| |||
67 | 83 | | |
68 | 84 | | |
69 | 85 | | |
70 | | - | |
71 | | - | |
72 | | - | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
73 | 91 | | |
74 | 92 | | |
75 | 93 | | |
| |||
0 commit comments