| @@ 22-32 (lines=11) @@ | ||
| 19 | ||
| 20 | protected $factory; |
|
| 21 | ||
| 22 | protected function configure() |
|
| 23 | { |
|
| 24 | $this |
|
| 25 | ->setName(self::COMMAND) |
|
| 26 | ->setDescription('Get a configuration value') |
|
| 27 | ->setHelp("This command retrieves a value for a specific configuration path") |
|
| 28 | ; |
|
| 29 | $this->addOption('use-flag', 'f', InputOption::VALUE_NONE, 'Get value as flag'); |
|
| 30 | $this->addArgument('path', InputArgument::REQUIRED, 'Configuration Path'); |
|
| 31 | $this->addArgument('context', InputArgument::OPTIONAL, 'Configuration Context', Config::CONTEXT_DEFAULT); |
|
| 32 | } |
|
| 33 | ||
| 34 | public function setConfigurationFactory(MagiumConfigurationFactoryInterface $factory) |
|
| 35 | { |
|
| @@ 17-27 (lines=11) @@ | ||
| 14 | ||
| 15 | const COMMAND = 'magium:configuration:list'; |
|
| 16 | ||
| 17 | protected function configure() |
|
| 18 | { |
|
| 19 | $this |
|
| 20 | ->setName(self::COMMAND) |
|
| 21 | ->setDescription('List configuration settings') |
|
| 22 | ->setHelp("This command lists all of the configuration setting values for the specified context, or 'default' if the context is not provided") |
|
| 23 | ; |
|
| 24 | ||
| 25 | $this->addArgument('path', InputArgument::REQUIRED, 'Configuration Path'); |
|
| 26 | $this->addArgument('context', InputArgument::OPTIONAL, 'Configuration Context', Config::CONTEXT_DEFAULT); |
|
| 27 | } |
|
| 28 | ||
| 29 | protected function execute(InputInterface $input, OutputInterface $output) |
|
| 30 | { |
|
| @@ 22-33 (lines=12) @@ | ||
| 19 | ||
| 20 | protected $factory; |
|
| 21 | ||
| 22 | protected function configure() |
|
| 23 | { |
|
| 24 | $this |
|
| 25 | ->setName(self::COMMAND) |
|
| 26 | ->setDescription('Set a configuration value') |
|
| 27 | ->setHelp("This command sets a value for a specific configuration path") |
|
| 28 | ; |
|
| 29 | ||
| 30 | $this->addArgument('path', InputArgument::REQUIRED, 'Configuration Path'); |
|
| 31 | $this->addArgument('value', InputArgument::REQUIRED, 'Value'); |
|
| 32 | $this->addArgument('context', InputArgument::OPTIONAL, 'Configuration Context', Config::CONTEXT_DEFAULT); |
|
| 33 | } |
|
| 34 | ||
| 35 | public function setConfigurationFactory(MagiumConfigurationFactoryInterface $factory) |
|
| 36 | { |
|