- Issue created by @RoSk0
- 🇳🇿New Zealand RoSk0 Wellington
When I tried to replicate this issue on a pure core 10.3 , unfortunately I don't have access to PHP 8.3 to testing on Drupal 11, the behaviour was different - requiring
main-settingslibrary scaffoldssettings.phpas expected, however requiringcustom-settingslibrary scaffolds thesettings-custom.phpand completely ignores the mainsettings.php- there is even no mention of it in the output related to thecustom-settingslibrary ... Feels like that file is completely ignored.However if I remove
main-settingslibrary and leavesettings.phpin place -custom-settingslibrary appends to it as expected:Scaffolding files for library/custom-settings: - NOTICE Modifying existing file at [web-root]/sites/default/settings.php. Examine the contents and ensure that it came out correctly. - Append to [web-root]/sites/default/settings.php from assets/settings-php-include.txt - Status changed to Closed: works as designed
over 1 year ago 3:08am 2 May 2024 - 🇳🇿New Zealand RoSk0 Wellington
I've already was burnt by the order once and somehow managed to forgot about it - order of the packages in the `allowed-packages` list is very important!
My libraries was ordered incorrectly in the top level
composer.json:"drupal-scaffold": { "allowed-packages": [ "library/custom-settings", "library/main-settings" ], }and it should be
"drupal-scaffold": { "allowed-packages": [ "library/main-settings", "library/custom-settings" ], }.
All of this is properly documented in the README.md "Allowed packages" section.