-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
feat(workspace-tools): add path support to --include, --exclude, and --from flags in foreach #5308
feat(workspace-tools): add path support to --include, --exclude, and --from flags in foreach #5308
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should instead extend the current options to support paths as well as idents, the --from
option should also be covered.
@merceyz My concern about doing that was that it's technically a breaking change if someone had idents & paths that both matched the same format - but I'm happy to make that change if it's not really a concern (as it'd be fairly unlikely) |
That looks good to me - @merceyz, have your concerns been addressed? |
Will go ahead and merge it to ship it in the next RC |
Yes, I missed the notification, sorry about that. |
Thanks for this change, @me4502! |
What's the problem this PR addresses?
Quite often, repos are laid out where workspaces are grouped by directories, but the workspace identifier is kept as the package name. This makes it hard to run a command on all workspaces that are within a
libs
directory for example, using the existingyarn workspaces foreach
command.How did you fix it?
This PR adds path support to the
--include
,--exclude
, and--from
flag in the foreach command in the workspace-tools plugin, allowing filtering of workspaces by relative path.Checklist