Skip to content

Commit

Permalink
Merge pull request #6689 from jasongrout/utilsworkspaces
Browse files Browse the repository at this point in the history
Support yarn configs with plain workspaces lists.
  • Loading branch information
blink1073 committed Jun 22, 2019
2 parents d5f0c6b + 13b695a commit 102dca5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion buildutils/src/utils.ts
Expand Up @@ -15,7 +15,8 @@ export function getLernaPaths(basePath = '.'): string[] {
basePath = path.resolve(basePath);
let baseConfig = require(path.join(basePath, 'package.json'));
let paths: string[] = [];
for (let config of baseConfig.workspaces.packages) {
let packages = baseConfig.workspaces.packages || baseConfig.workspaces;
for (let config of packages) {
paths = paths.concat(glob.sync(path.join(basePath, config)));
}
return paths.filter(pkgPath => {
Expand Down

0 comments on commit 102dca5

Please sign in to comment.