internal-dependencies
Calculate package dependencies living in the same monorepo
Install
npm install --save-dev @typescript-tools/internal-dependencies
Use
Usage:
internal-dependencies [--path] <root> <package>...
Options:
root Root of lerna mono-repository
packages Packages to print dependencies of (also reads from stdin)
--path Print the relative path to each package from root
Example
internal-dependencies
can read one or more package names (the name
property in the package's package.json
) either as arguments or stdin.
It outputs the internal dependencies that the list of packages depends
upon, either directly or transitively.
$ echo @typescript-tools/lerna-utils | node ./packages/internal-dependencies/dist/src/internal-dependencies.js .
@typescript-tools/io-ts
Use --path
to print the path to the dependencies rather than the
package names.
$ internal-dependencies --path . @typescript-tools/internal-dependencies
packages/io-ts
packages/lerna-utils