class ConfigSplitCommands in Configuration Split 8
Same name and namespace in other branches
- 2.0.x src/Commands/ConfigSplitCommands.php \Drupal\config_split\Commands\ConfigSplitCommands
Class ConfigSplitCommands.
This is the Drush 9 and 10 commands.
@package Drupal\config_split\Commands
Hierarchy
- class \Drupal\config_split\Commands\ConfigSplitCommands extends \Drush\Commands\DrushCommands
Expanded class hierarchy of ConfigSplitCommands
1 string reference to 'ConfigSplitCommands'
1 service uses ConfigSplitCommands
File
- src/
Commands/ ConfigSplitCommands.php, line 15
Namespace
Drupal\config_split\CommandsView source
class ConfigSplitCommands extends DrushCommands {
/**
* The interoperability cli service.
*
* @var \Drupal\config_split\ConfigSplitCliService
*/
protected $cliService;
/**
* ConfigSplitCommands constructor.
*
* @param \Drupal\config_split\ConfigSplitCliService $cliService
* The CLI service which allows interoperability.
*/
public function __construct(ConfigSplitCliService $cliService) {
$this->cliService = $cliService;
}
/**
* Export only split configuration to a directory.
*
* @param string $split
* The split configuration to export, if none is given do a normal export.
*
* @command config-split:export
*
* @usage drush config-split:export development
* Export development configuration; assumes a "development" split export
* only that.
*
* @aliases csex
*/
public function splitExport($split = NULL) {
$this->cliService
->ioExport($split, $this
->io(), 'dt');
}
/**
* Import only config from a split.
*
* @param string $split
* The split configuration to export, if none is given do a normal import.
*
* @command config-split:import
*
* @usage drush config-split:import development
* Import development configuration; assumes a "development" split import
* only that.
*
* @aliases csim
*/
public function splitImport($split = NULL) {
$this->cliService
->ioImport($split, $this
->io(), 'dt');
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigSplitCommands:: |
protected | property | The interoperability cli service. | |
ConfigSplitCommands:: |
public | function | Export only split configuration to a directory. | |
ConfigSplitCommands:: |
public | function | Import only config from a split. | |
ConfigSplitCommands:: |
public | function | ConfigSplitCommands constructor. |