Add multiple packages in a single command
See original GitHub issueExpected Behavior
The following command would allow a user to add the bar
and baz
packages to the foo
package.
lerna add --scope=foo bar baz
Current Behavior
Currently you can only add one package at a time. To achieve the goal of the previous example, you must run the following.
lerna add --scope=foo bar
lerna add --scope=foo baz
Context
It’s quite common to install multiple npm packages as dependencies.
npm i -D eslint eslint-config-standard eslint-plugin-standard eslint-plugin-node eslint-plugin-import eslint-plugin-promise eslint-plugin-react
npm i -D @babel/core @babel/preset-env @babel/preset-react
npm i -D react react-dom redux react-redux react-router-dom
npm i -D webpack webpack-cli webpack-dev-server babel-loader file-loader css-loader style-loader
Intuitively, lerna should also allow this behavior.
#1608 was opened to request this feature, but no discussion came from it. The result was essentially “lerna doesn’t do this” and the reason given was vague.
The ambiguity of targets forced a simplification of logic.
I’m not sure what that is supposed to mean, but this behavior caught me out the first time I tried to use lerna because I just expected it to work like npm.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:66
- Comments:20
Top Results From Across the Web
Add multiple packages in single command in flutter
I can do the job by simply adding those packages in pubspec.yaml file and then in command line write this command flutter pub...
Read more >How to install multiple npm packages with one command
The npm install command is used to install npm packages to a node_modules/ folder. ... You can also install a specific version of...
Read more >If I try to install multiple packages with one "apt" command, it is ...
You would solve it by using the command plainly without the extra options and having the correct sources for your distribution.
Read more >Installing multiple nuget packages in one command - Medium
One of my problems with nuget is that I can't install multiple packages in one command while we can do the same in...
Read more >Managing packages - Conda
To install multiple packages at once, such as SciPy and cURL: ... on a specific package in your environment, there is not one...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Pls fix…
Jesus the error message when you try to add multiple packages is so cryptic, it took me ages to find out what’s wrong.
Hopefully writing the error message here helps someone googling: “No packages found where can be added.”