1
0
Fork 0

added no-custom-installers option to install/update command

pull/938/head
Johannes M. Schmitt 2012-07-22 01:06:28 +02:00
parent 48662e9b17
commit ec74e422f4
2 changed files with 10 additions and 0 deletions

View File

@ -33,6 +33,7 @@ class InstallCommand extends Command
new InputOption('prefer-source', null, InputOption::VALUE_NONE, 'Forces installation from package sources when possible, including VCS information.'),
new InputOption('dry-run', null, InputOption::VALUE_NONE, 'Outputs the operations but will not execute anything (implicitly enables --verbose).'),
new InputOption('dev', null, InputOption::VALUE_NONE, 'Enables installation of dev-require packages.'),
new InputOption('no-custom-installers', null, InputOption::VALUE_NONE, 'Disables all custom installers.'),
new InputOption('no-scripts', null, InputOption::VALUE_NONE, 'Skips the execution of all scripts defined in composer.json file.'),
))
->setHelp(<<<EOT
@ -61,6 +62,10 @@ EOT
->setRunScripts(!$input->getOption('no-scripts'))
;
if ($input->getOption('no-custom-installers')) {
$install->disableCustomInstallers();
}
return $install->run() ? 0 : 1;
}
}

View File

@ -33,6 +33,7 @@ class UpdateCommand extends Command
new InputOption('prefer-source', null, InputOption::VALUE_NONE, 'Forces installation from package sources when possible, including VCS information.'),
new InputOption('dry-run', null, InputOption::VALUE_NONE, 'Outputs the operations but will not execute anything (implicitly enables --verbose).'),
new InputOption('dev', null, InputOption::VALUE_NONE, 'Enables installation of dev-require packages.'),
new InputOption('no-custom-installers', null, Input::VALUE_NONE, 'Disables all custom installers.'),
new InputOption('no-scripts', null, InputOption::VALUE_NONE, 'Skips the execution of all scripts defined in composer.json file.'),
))
->setHelp(<<<EOT
@ -67,6 +68,10 @@ EOT
->setUpdateWhitelist($input->getArgument('packages'))
;
if ($input->getOption('no-custom-installers')) {
$install->disableCustomInstallers();
}
return $install->run() ? 0 : 1;
}
}