Filtering Packages
Each Melos command can be used alongside the following global filters:
--no-private
Exclude private packages (publish_to: none
). They are included by default.
melos bootstrap --no-private
--published
Filter packages where the current local package version exists on pub.dev.
melos bootstrap --published
Use --no-published
to filter packages that have not had their current version published yet.
--scope
Include only packages with names matching the given glob. This option can be repeated.
# Run `flutter build ios` on all packages with "example" in the package name
melos exec --scope="*example*" -- flutter build ios
--ignore
Exclude packages with names matching the given glob. This option can be repeated.
# Run `flutter build ios` on all packages but ignore those whose packages names contain "internal"
melos exec --ignore="*internal*" -- flutter build ios
--since
Only include packages that have been changed since the specified ref
, e.g. a commit sha or git tag.
# Run `flutter build ios` on all packages that have been changed since the specified commit hash
melos exec --since=<commit hash> -- flutter build ios
--dir-exists
Include only packages where a specific directory exists inside the package.
# Only bootstrap packages with an example directory
melos bootstrap --dir-exists="example"
--file-exists
Include only packages where a specific file exists in the package.
# Only bootstrap packages with an README.md file
melos bootstrap --file-exists="README.md"