If we add a new install step to the LDG profile, and use that to call a hook, we can use that hook in our own modules to perform tasks later in the install process than using hook_install() or hook_modules_installed() would allow.
The specific use case we want this for is to allow localgov_core to install default blocks on behalf of other modules during the installer. If we use hook_modules_installed() for this, it's too early in the install process, and the site's themes aren't set up yet.
Adding our own install step solves this problem by running much later in the install process. The only thing that comes after is downloading translation data.
This idea comes from the conversation in https://github.com/localgovdrupal/localgov_core/pull/212
If we add a new install step to the LDG profile, and use that to call a hook, we can use that hook in our own modules to perform tasks later in the install process than using hook_install() or hook_modules_installed() would allow.
The specific use case we want this for is to allow localgov_core to install default blocks on behalf of other modules during the installer. If we use hook_modules_installed() for this, it's too early in the install process, and the site's themes aren't set up yet.
Adding our own install step solves this problem by running much later in the install process. The only thing that comes after is downloading translation data.