Allow to set configuration values directly in the command line

This commit is contained in:
Stéphane Goetz
2017-11-05 23:56:46 +01:00
bovenliggende 55ee848e32
commit 8e7340da3d
3 gewijzigde bestanden met toevoegingen van 50 en 9 verwijderingen

Bestand weergeven

@ -11,22 +11,21 @@ class Generate extends DauxCommand
{
protected function configure()
{
parent::configure();
$description = 'Destination folder, relative to the working directory';
$this
->setName('generate')
->setDescription('Generate documentation')
->addOption('configuration', 'c', InputOption::VALUE_REQUIRED, 'Configuration file')
->addOption('source', 's', InputOption::VALUE_REQUIRED, 'Where to take the documentation from')
->addOption('format', 'f', InputOption::VALUE_REQUIRED, 'Output format, html or confluence', 'html')
->addOption('processor', 'p', InputOption::VALUE_REQUIRED, 'Manipulations on the tree')
->addOption('themes', 't', InputOption::VALUE_REQUIRED, 'Set a different themes directory')
// Confluence format only
->addOption('delete', null, InputOption::VALUE_NONE, 'Delete pages not linked to a documentation page (confluence)')
// HTML Format only
->addOption('themes', 't', InputOption::VALUE_REQUIRED, 'Set a different themes directory')
->addOption('destination', 'd', InputOption::VALUE_REQUIRED, $description, 'static')
->addOption('search', null, InputOption::VALUE_NONE, 'Generate full text search');
}