Allow setting the channel without running a complete self-update
parent
34d7e26f25
commit
5061d90135
|
@ -51,6 +51,7 @@ class SelfUpdateCommand extends BaseCommand
|
|||
new InputOption('stable', null, InputOption::VALUE_NONE, 'Force an update to the stable channel'),
|
||||
new InputOption('preview', null, InputOption::VALUE_NONE, 'Force an update to the preview channel'),
|
||||
new InputOption('snapshot', null, InputOption::VALUE_NONE, 'Force an update to the snapshot channel'),
|
||||
new InputOption('set-channel-only', null, InputOption::VALUE_NONE, 'Only store the channel as the default one and then exit'),
|
||||
))
|
||||
->setHelp(<<<EOT
|
||||
The <info>self-update</info> command checks getcomposer.org for newer
|
||||
|
@ -85,6 +86,10 @@ EOT
|
|||
}
|
||||
}
|
||||
|
||||
if ($input->getOption('set-channel-only')) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
$cacheDir = $config->get('cache-dir');
|
||||
$rollbackDir = $config->get('data-dir');
|
||||
$home = $config->get('home');
|
||||
|
|
Loading…
Reference in New Issue