Have update.php call a hook for update tasks

Created on 15 January 2011, over 13 years ago
Updated 20 May 2023, over 1 year ago

It would be helpful to add a hook to the update system to allow a module or theme to add a task to the list of updates without actually defining a hook_update_N function. There will need to be some alternate way of defining what the final schema version is of the module/install profile upon completion.

The use case I am trying to solve is marrying Profiler and Update API, so that Profiler can read in the .info file of an install profile (which is where install profiles that implement Profiler define their installation tasks), check to see if the schema version has changed from what is defined in the database, and if so, run a task that calls Update API functions to iterate over what is defined in the .info and make changes to the database if necessary. This means that an install profile author that implements Profiler could simply make changes to their .info file, increment the schema version defined in the .info file, and have essentially written an update for their install profile without have touched a line of PHP code.

Feature request
Status

Closed: won't fix

Version

7.0 ⚰️

Component
Database update 

Last updated 9 days ago

No maintainer
Created by

🇺🇸United States q0rban Atlanta, GA

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.

  • 🇳🇿New Zealand quietone New Zealand

    This is about Profiler, a project that has a release for Drupal 7 and none for Drupal 8+. Therefor, moving to Drupal 7. I am also closing this because Drupal 7 is not introducing new APIs.

Production build 0.71.5 2024