Skip to content
PHP Ecosystem
Explore

ConsoleUtil

API reference › Foxy › Util › ConsoleUtil

final classFoxy\Util\ConsoleUtil
Sourcesrc/Util/ConsoleUtil.php

Helper for console.

MethodDescriptionDefined by
getInput() staticGet the console input.ConsoleUtil
getPreferredInstallOptions() staticReturns preferSource and preferDist values based on the configuration.ConsoleUtil
public static function getInput(Composer\IO\IOInterface $io): Symfony\Component\Console\Input\InputInterface

Get the console input.

Parameters

ParameterTypeDescription
$ioComposer\IO\IOInterfaceThe IO

Returns

Symfony\Component\Console\Input\InputInterface

public static function getPreferredInstallOptions(Composer\Config $config, Symfony\Component\Console\Input\InputInterface $input): array

Returns preferSource and preferDist values based on the configuration.

Parameters

ParameterTypeDescription
$configComposer\ConfigThe composer config.
$inputSymfony\Component\Console\Input\InputInterfaceThe console input

Returns

array