I would like to install all the dependencies that are maintained by me using the "prefer source" option, and all the other dependencies not maintained by me using "prefer dist".
Is that possible with Composer? I was thinking there might be something like this, but I couldn't find it:
"my/dependency":"v1.2.3@dist",
"other/dependency":"v4.5.6@source",
Any ideas?
There is now a preferred-install feature. (I'm not sure if this was available at the time of the original question)
Defaults to auto and can be any of source, dist or auto. This option allows you to set the install method Composer will prefer to use. Can optionally be a hash of patterns for more granular install preferences.
{
"config": {
"preferred-install": {
"my-organization/stable-package": "dist",
"my-organization/*": "source",
"partner-organization/*": "auto",
"*": "dist"
}
}
}
This lets you specify for each dependency the preferred install method.
See the repositories section for available ways the dependencies can be host.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With