On this page
function install_install_profile
install_install_profile(&$install_state)
Installs the install profile.
Parameters
$install_state: An array of information about the current installation state.
File
- core/includes/install.core.inc, line 1552
- API functions for installing Drupal.
Code
function install_install_profile(&$install_state) {
\Drupal::service('module_installer')->install(array(drupal_get_profile()), FALSE);
// Install all available optional config. During installation the module order
// is determined by dependencies. If there are no dependencies between modules
// then the order in which they are installed is dependent on random factors
// like PHP version. Optional configuration therefore might or might not be
// created depending on this order. Ensuring that we have installed all of the
// optional configuration whose dependencies can be met at this point removes
// any disparities that this creates.
\Drupal::service('config.installer')->installOptionalConfig();
// Ensure that the install profile's theme is used.
// @see _drupal_maintenance_theme()
\Drupal::service('theme.manager')->resetActiveTheme();
}
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!includes!install.core.inc/function/install_install_profile/8.1.x