-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes dependencies using bins from their own dependencies (#6712)
- Loading branch information
Showing
4 changed files
with
45 additions
and
3 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
packages/pkg-tests/pkg-tests-fixtures/packages/one-dep-scripted-1.0.0/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* @flow */ | ||
|
||
module.exports = require(`./package.json`); | ||
|
||
for (const key of [`dependencies`, `devDependencies`, `peerDependencies`]) { | ||
for (const dep of Object.keys(module.exports[key] || {})) { | ||
// $FlowFixMe The whole point of this file is to be dynamic | ||
module.exports[key][dep] = require(dep); | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
packages/pkg-tests/pkg-tests-fixtures/packages/one-dep-scripted-1.0.0/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"name": "one-dep-scripted", | ||
"version": "1.0.0", | ||
"dependencies": { | ||
"has-bin-entries": "1.0.0" | ||
}, | ||
"scripts": { | ||
"install": "has-bin-entries" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters