You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As outlined in cweagans/composer-patchesdocumentation, the patch list can either be included directly in composer.json or in a dedicated patches.json file - or even any JSON file as long as it is specified in composer.json's extra.patches-file property.
A dedicated file is useful to remove some bloat from composer.json, however, this package seem to always place new patches directly in composer.json. It would be interested if it was possible to override this behavior and even adopt some smart assumptions. So I would propose a few changes to allow that:
Change default behavior when deciding where to add the patch entry:
if extra.patches-file is set in composer.json, use that field's value
else, if patches.json exists, use that
else, fallback to composer.json
Add a --patches-file option that allows overriding default behavior
Default behavior suggestion is based on a) following cweagans/composer-patches configuration and b) assuming if patches.json exist, it must be being used, but I'm open 'to hearing your thoughts on this.
I'd be happy to work on a PR to implement this change, just let me know what you think.
The text was updated successfully, but these errors were encountered:
As outlined in
cweagans/composer-patches
documentation, the patch list can either be included directly incomposer.json
or in a dedicatedpatches.json
file - or even any JSON file as long as it is specified incomposer.json
'sextra.patches-file
property.A dedicated file is useful to remove some bloat from
composer.json
, however, this package seem to always place new patches directly incomposer.json
. It would be interested if it was possible to override this behavior and even adopt some smart assumptions. So I would propose a few changes to allow that:extra.patches-file
is set incomposer.json
, use that field's valuepatches.json
exists, use thatcomposer.json
--patches-file
option that allows overriding default behaviorDefault behavior suggestion is based on a) following
cweagans/composer-patches
configuration and b) assuming ifpatches.json
exist, it must be being used, but I'm open 'to hearing your thoughts on this.I'd be happy to work on a PR to implement this change, just let me know what you think.
The text was updated successfully, but these errors were encountered: