-
-
Notifications
You must be signed in to change notification settings - Fork 365
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Autogenerate sprinkles.json #747
Comments
So I've started doing some research on this. My hopes that we could actually use Composer to manage the sprinkle seams less promising than initially expected, but things might change with Composer 2.0. One of two ways to address this would be to create a custom script that would generated the This is nice, as Composer already know about each package path and namespace already. But at the same time, it means all sprinkles would need to be loaded by composer, which brings it's own complication when setting a simple, "local" sprinkle. If reading Moreover, instead of defining only the sprinkles we want to load by name, we should reference them by a main class. For example :
Note that location could be attracted from the class (we can use This "main class" would be necessary anyway to handle new CI service registration, and to explicitly register migrations, bakery commands, etc. It would also make it simpler to implement sprinkle vendor name (#831). Even when reading the As for simple, local sprinkles : assuming Core, Account and Admin are loaded by Composer and not included in the "base" installation (Ref #830), since we don't want to depend on the merge plugin anymore, I believe it makes sense to have their PSR definitions in that main Overall, it might make it more difficult to create a CLI command to manage sprinkles (Ref #728 & #729), as we would need to read and write to the main |
I should note, |
Not relevant for UF5 anymore |
Since all sprinkles should have a
composer.json
file, it shouldn't be hard to generate thesprinkles.json
automatically when runningcomposer update
. A previous concerns was the specific order of sprinkles, but since each of those composer file should have dependencies, it shouldn't be harder than ordering the migrations.The issue here is while a sprinkle can define requirements and load other sprinkles automatically, you still have to add those dependencies to the
sprinkles.json
.Related to #728 .
This should probably helps with #597. Since each sprinkles should have a type of
userfrosting-sprinkle
, themes could/may haveuserfrosting-theme
type.The text was updated successfully, but these errors were encountered: