Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(core): ignore node_modules and .git folders for workspaces #1480

Merged
merged 2 commits into from
Jun 14, 2020

Conversation

merceyz
Copy link
Member

@merceyz merceyz commented Jun 14, 2020

What's the problem this PR addresses?

When specifying a globstar pattern for workspaces, the node_modules folders aren't ignored which causes duplicate workspace name errors.

Fixes #1297
Fixes #1191

How did you fix it?

Ignore node_modules and .git folders when searching for workspaces

Checklist

  • I have read the Contributing Guide.
  • I have set the packages that need to be released for my changes to be effective.
  • I have verified that all automated PR checks pass.

@merceyz merceyz requested a review from arcanis as a code owner June 14, 2020 16:39
@arcanis arcanis merged commit adbb358 into master Jun 14, 2020
@arcanis arcanis deleted the merceyz/workspaces-glob branch June 14, 2020 17:33
@@ -69,6 +69,7 @@ export class Workspace {
expandDirectories: false,
onlyDirectories: true,
onlyFiles: false,
ignore: [`node_modules`, `.git`],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't the .yarn folder be ignored as well, btw? Otherwise it'll detect the unplugged directory.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, it should. I forgot about that one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants