Problem/Motivation

Generation has to run in a deployment and in CI, not only from an administration page, and it has to be possible to see what a generation would do before it does it — on a site whose API the front end depends on, a blind regeneration is not acceptable.

Proposed resolution

  • drush myrest:generate, with options to limit to one bundle or endpoint, and a dry-run mode.
  • drush myrest:diff printing what would change: files added, files rewritten, files skipped, conflicts, and configuration entities that would change.
  • Exit codes that let CI fail when the committed generated code is out of date with the model — the check that keeps the repository honest.
  • No interactive prompts in either, so they work unattended.

Remaining tasks

Everything.

Issue fork myrest-3621962

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

sergeydruua created an issue. See original summary.

  • sergeydruua committed df2b1c56 on 1.0.x
    Issue #3621962: Add drush myrest:generate and myrest:diff
    
sergeydruua’s picture

Status: Active » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

sergeydruua’s picture

Status: Fixed » Closed (fixed)