backdrop / backdrop-issues

Issue tracker for Backdrop core.
144 stars 40 forks source link

[META] Recipes 2.0 (a.k.a. the "Master Chef" initiative) #6595

Open klonos opened 5 months ago

klonos commented 5 months ago

This is a follow-up of #5240.

I will loop back to refine this. For now, here's a copy/paste from the relevant discussion thread in Zulip:

I've already reviewed the code of several recipe modules, and although I understand the value they provide as they are currently, I also already see their limitations and things that are against what the initial plan for recipes was (no-code, or very minimal code - definitely no php or js). What I would like recipes to be is "code-less scripts" or natural-language (sorta) "instructions". I started creating a custom module called master_chef :sweat_smile: ...which would be the equivalent of what the Drupal recipe runner is. I quickly realized though that I would need hooks that are not currently available in Backdrop core. That means that I would have to file several issues in the core queue for feature requests, which would scatter pieces of my puzzle all over the place + I would then be blocked from making any progress until these things were implemented. What I think I will do is I will create a meta-issue in core (this one here 😉), which will allow me to provide a PoC PR with a very minimal implementation.

To get an idea of what recipes look like in Drupal, have a look here for some examples: https://git.drupalcode.org/project/drupal/-/blob/11.x/core/recipes

I would like Backdrop recipes to be as simple as these ...even simpler than that if possible! I would like anyone that can read through a how-to article or watch a tutorial video to be able to convert it to machine-readable, yet plain-language (as much as possible) instructions set with very minimal effort, and no code (almost no code - writing a .json or .info file is still "code"). I want recipes to resemble as much as possible an actual food recipe, and have its simplicity:

  1. start with a name for the "dish"
  2. add a section of required "ingredients" (dependencies on modules/themes/templates, which the project installer can pull and install)
  3. provide the actual recipe instructions (steps outlined in the .info file ideally, which will be followed/executed sequentially)
  4. sprinkle some "seasoning" if required (things like CSS - possibly via modules like css_injector, which will have already been added as one of the "ingredients" in step 2)

Some relevant core issues (for now, this includes issues mentioned in #5240, as there's naturally a lot of overlap):

With the fix of https://github.com/backdrop/backdrop-issues/issues/3224, we are moving closer towards developing the preconditions for "recipes" to become a more useful tool in Backdrop.

See:

This is intended as a META issue to track other issues that are blocking the progress of "recipes" and/or are directly related to the advancement of "recipes."

klonos commented 5 months ago

There are a couple of cases in core at the moment that I can think of where recipes would be a good fit:

Please feel free to suggest more. I'm looking for very simple tasks at the moment, in order to create an MVP:

...things like that. The simpler, the better.