Exec Command
Supports all Melos filtering flags.
Execute an arbitrary command in each package.
melos exec
# e.g. melos exec -- pub global run tuneup check
The command is executed in a shell. On Windows the shell is cmd.exe
and on all
other platforms it is sh
.
If multiple commands are being executed and no further commands should be
executed after a command has failed, connect the commands with &&
:
melos exec -- "melos bootstrap && melos run build"
It is important to pass multiple commands as a single string to melos exec
,
otherwise the shell will pass only the first command to melos exec
.