2017 © Pedro Peláez
 

library drupal-code-builder

Code generator for Drupal

image

drupal-code-builder/drupal-code-builder

Code generator for Drupal

  • Thursday, July 26, 2018
  • by joachim-n
  • Repository
  • 1 Watchers
  • 14 Stars
  • 1,071 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 3 Forks
  • 30 Open issues
  • 41 Versions
  • 54 % Grown

The README.md

Drupal Code Builder is a system for generating scaffold code for Drupal modules (and other components)., (*1)

This is a library, and has no UI of its own. It can be used in several ways: - with the Drupal Module Builder project, which provides a UI within Drupal. (The Drupal Code Builder library was formerly part of the Module Builder module.) - with the Drush command extension., (*2)

Drupal Code Builder can be used for any current version of Drupal. Older versions are unsupported, but it should produce code for versions going far back as Drupal 5., (*3)

Tests powered by PHPUnit ensure that the generated PHP code passes PHP linting, and adheres to Drupal Coding Standards, as enforced by PHP CodeSniffer., (*4)

What Drupal Code Builder can do

Drupal Code Builder can generate the following for a module: - code files, containing hook implementations - info.yml file (.info file on Drupal 7 and older) - README file - PHPUnit test case classes, with presets for different types - Simpletest test case classes - annotated class plugins - YAML file plugins - services, with presets for tagged service types - content entity types, with bundle entity and base fields - config entity types, with properties - plugin types - theme hooks, (*5)

Definitions of hooks, plugin types, and tagged service types are obtained by analyzing the current Drupal codebase of the site where the library is used. This means that Drupal Code Builder automatically knows about all hooks and plugin types from contrib and custom modules as well as those in Drupal core., (*6)

Furthermore, complex subcomponents can generate multiple code elements: - an admin settings form adds form builder functions and an admin permission - router paths add menu/router items - permission names add the scaffold for the permission definition, (*7)

Installation

Follow the instructions given in the component that requests Drupal Coder Builder (e.g., Module Builder, Drush command)., (*8)

Additionally, if Plugin module is present, plugin type definitions will be enhanced with its data., (*9)

The Versions

12/06 2018
24/05 2018
02/11 2017

3.1.x-dev

3.1.9999999.9999999-dev

  Sources   Download

GPL-2.0+

The Development Requires

29/09 2017

dev-feature-generate-task-helpers-refactor

dev-feature-generate-task-helpers-refactor

  Sources   Download

GPL-2.0+

The Development Requires

12/09 2017

3.1.0

3.1.0.0

  Sources   Download

GPL-2.0+

The Development Requires

11/09 2017

3.0.x-dev

3.0.9999999.9999999-dev

  Sources   Download

GPL-2.0+

The Development Requires

28/08 2017

3.0.1

3.0.1.0

  Sources   Download

GPL-2.0+

The Development Requires

21/04 2017

3.0.0

3.0.0.0

  Sources   Download

GPL-2.0+

The Development Requires