Skip to content

Feature request: decouple input logic from generation logic to enable non-interactive use (e.g., REST services) #208

@damian-psiware

Description

@damian-psiware

Hi! First of all, thank you for this excellent tool — we’ve found drupal-code-generator very helpful for automating scaffolding in our Drupal projects.

I'm currently exploring a use case where we want to trigger code generation from a REST API instead of from the CLI. However, I’ve found that the input logic (interactive questions, options, etc.) is tightly coupled with the code generation logic.

Is there a way to achieve this functionality using the current codebase?

I’m considering creating a class in the same spirit as BaseGenerator, but designed to generate files using an array of structured input data instead. If you've already implemented something like this or can provide any guidance, that would be greatly appreciated!

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions