Allow adding help to existing modules

Created on 27 August 2010, almost 14 years ago
Updated 1 October 2023, 9 months ago

Currently helpinject produces standalone modules, which have valid use cases, but in many cases it would be useful to add help to existing modules. Related issue: #428624: Drush support, including adding help to an existing module β†’ .

Proposed approach:

  • Create new module, helpinjector, which implements hook_help() and hook_form_alter(). Implementations simply call hook_helpinjector_help() and drupal_alter('helpinjector_form'). Also includes versions of the helper functions and CSS currently put into each helpinjector-created module.
  • Declare constants, HELPINJECT_EXPORT_DEPENDENT and HELPINJECT_EXPORT_STANDALONE
  • In export, if mode is HELPINJECT_EXPORT_DEPENDENT:
    • skip some of the functions (those moved to helpinjector)
    • adjust function calls and classes to use helpinjector versions.
    • put hook_helpinjector_help() and hook_helpinjector_form_alter() in modulename.hellpinjector.inc file
    • .module file calls module_load_include() for .inc file
✨ Feature request
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada nedjo

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024