Description
After the last release, the .drupal-updater.yml configuration introduced a new limit option for the number of packages to update. However, when specifying the --packages parameter manually via the CLI, the command fails if limit is also defined in the configuration file.
Steps to Reproduce
-
Define a .drupal-updater.yml file with a limit option, for example:
-
Run the command specifying packages manually:
drupal-updater --environments="@self" --author="jenkins <jenkins@drupal-update>" \
--packages="drupal/metatag,drupal/name,drupal/modal_page,drupal/pathauto,drupal/views_data_export"
Actual Behavior
Selected configuration file: .drupal-updater.yml
Configuration file found at .drupal-updater.yml
In Config.php line 242:
The parameter packages and limit can't be used toguether.
Expected Behavior
The command-line parameter (--packages) should take priority over the configuration file.
If packages is explicitly defined, the tool should ignore the limit option from the config file, using it only as a default when --packages is not provided.
Suggested Fix
Allow both packages and limit to coexist, giving priority to command-line arguments and treating the config file as a fallback/default.