function drush_config_devel_import in Configuration development 8
Drush command callback.
File
- drush/
config_devel.drush.inc, line 103 - Configuration development module drush integration.
Code
function drush_config_devel_import($extension) {
// Determine the type of extension we're dealing with.
$type = drush_config_devel_get_type($extension);
if ($type) {
// Get the config
$config = drush_config_devel_get_config($type, $extension);
// Import config
if (isset($config['install'])) {
drush_config_devel_import_config($config['install'], $type, $extension, InstallStorage::CONFIG_INSTALL_DIRECTORY);
}
// Import optional config
if (isset($config['optional'])) {
drush_config_devel_import_config($config['optional'], $type, $extension, InstallStorage::CONFIG_OPTIONAL_DIRECTORY);
}
}
else {
drush_set_error("Couldn't import configuration. The '{$extension}' extension is not enabled.");
}
}