admin管理员组

文章数量:1322012

I'm using lerna to manage my monorepo, for some reason, when I try to run the following mand from the root folder (using the docs here): lerna run --scope my-app test I get the following error of lerna didn't find the module to run npm test on:

lerna notice cli v3.20.2
lerna info versioning independent
lerna notice filter including "my-app"
lerna info filter [ 'my-app' ]
lerna ERR! EFILTER No packages remain after filtering [ 'my-app' ]

My lerna.json file has this definitions:

"packages": [
    "app1",
    "some-package-with-my-app/*",
    "app2",
    "app3"
  ],

I also tried to run lerna run --scope some-package-with-my-app/my-app test but got the same error (with the corresponding filter name, of course)

What am I doing wrong? Am I missing something in the docs?

I'm using lerna to manage my monorepo, for some reason, when I try to run the following mand from the root folder (using the docs here): lerna run --scope my-app test I get the following error of lerna didn't find the module to run npm test on:

lerna notice cli v3.20.2
lerna info versioning independent
lerna notice filter including "my-app"
lerna info filter [ 'my-app' ]
lerna ERR! EFILTER No packages remain after filtering [ 'my-app' ]

My lerna.json file has this definitions:

"packages": [
    "app1",
    "some-package-with-my-app/*",
    "app2",
    "app3"
  ],

I also tried to run lerna run --scope some-package-with-my-app/my-app test but got the same error (with the corresponding filter name, of course)

What am I doing wrong? Am I missing something in the docs?

Share Improve this question asked Jan 22, 2020 at 16:02 Ziv LevyZiv Levy 2,0443 gold badges22 silver badges38 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 9

The package named my-app was scoped with my organisation name. i.e. the name as appeared in my package.json file was @org/my-app so once running lerna run --scope @org/my-app test it worked perfectly

本文标签: javascriptrunning test command using lerna managed monorepo using scope failsStack Overflow