Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Create devcontainer.json #86

Open
wants to merge 54 commits into
base: 7.1
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
a1b3df8
[Console] Better error handling when misuse of `ArgvInput` with arrays
symfonyaml Apr 12, 2024
aaef070
bug #54576 [Console] Better error handling when misuse of `ArgvInput`…
fabpot Jun 3, 2024
d4f6891
Prefix all sprintf() calls
derrabus Jun 20, 2024
f63a2ee
chore: CS fixes
keradus Jun 16, 2024
5ed7b6c
Add return type to __toString() methods
seriquynh Jun 28, 2024
b71a095
Merge branch '7.1' into 7.2
nicolas-grekas Jun 28, 2024
d36a5fe
Update .gitattributes
fabpot Jul 6, 2024
22e3436
[Console] Remove a redundant check in `ErrorListener`
seriquynh Jul 18, 2024
f807c53
Replace `TestCase::assertTrue(true)` with `TestCase::expectNotToPerfo…
alexandre-daubois Jul 22, 2024
43b48b2
Use CPP where possible
alexandre-daubois Jul 22, 2024
2bac616
Merge branch '7.1' into 7.2
xabbuh Jul 24, 2024
21e08e0
minor #57795 Use CPP where possible (alexandre-daubois)
fabpot Jul 25, 2024
2d8cffd
Merge branch '7.1' into 7.2
nicolas-grekas Jul 26, 2024
8b3ee1c
[Cache][Config][Console][DependencyInjection][FrameworkBundle] Remove…
alexandre-daubois Jul 19, 2024
b54fbe5
Create devcontainer.json
norbertosus Jul 26, 2024
d48400b
Remove unused code and unnecessary `else` branches
alexandre-daubois Jul 31, 2024
7d6b78e
Code style change in `@PER-CS2.0` affecting `@Symfony` (parentheses f…
bonroyage Aug 1, 2024
a228c54
minor #57901 Code style change in ``@PER`-CS2.0` affecting ``@Symfony…
derrabus Aug 6, 2024
2204ca3
Merge branch '7.1' into 7.2
xabbuh Aug 12, 2024
7884dc7
[PhpUnitBridge][Console][VarDumper] Add support for `FORCE_COLOR` env…
serious-angel Jul 19, 2024
7e27871
feature #57777 [VarDumper] Add support for `FORCE_COLOR` environment …
nicolas-grekas Aug 13, 2024
3c43d7e
Merge branch '7.1' into 7.2
nicolas-grekas Aug 13, 2024
cc2dd55
Merge branch '7.1' into 7.2
chalasr Aug 15, 2024
ee7ee22
[Console][Process] Add `$verbosity` argument to `mustRun` helper method
willrowe Aug 23, 2024
07d683c
no longer use the internal TestFailure class
xabbuh Sep 5, 2024
4843e24
Merge branch '7.1' into 7.2
derrabus Sep 8, 2024
07792b2
Merge branch '7.1' into 7.2
derrabus Sep 20, 2024
e57e6e0
[Console] Add silent verbosity mode suppressing all output, including…
wouterj Sep 19, 2024
300899a
Fix `$this` calls to static ones when relevant
alexandre-daubois Sep 24, 2024
dde368a
Remove useless parent method calls in tests
alexandre-daubois Sep 24, 2024
a113dc3
Merge branch '7.1' into 7.2
nicolas-grekas Sep 25, 2024
96ca566
Merge branch '7.1' into 7.2
nicolas-grekas Sep 25, 2024
dbccd36
Remove unused imports
alexandre-daubois Sep 26, 2024
dfd8158
minor #58374 Remove useless parent method calls in tests (alexandre-d…
fabpot Sep 27, 2024
c8b5404
Merge branch '7.1' into 7.2
xabbuh Sep 28, 2024
e31f47c
Remove a few unnecessary full qualifier
alexandre-daubois Oct 1, 2024
6f86f8d
Add finished indicator to ProgressIndicator
LauLaman Jun 28, 2024
8453956
Various CS fix for consistency
alexandre-daubois Oct 3, 2024
270fd98
[Console] Use assertSame for input tests
theofidry Oct 4, 2024
721a55b
minor #58443 Various CS fix for consistency (alexandre-daubois)
fabpot Oct 6, 2024
b4f6757
feature #57576 [Console] Add finished indicator to `ProgressIndicator…
fabpot Oct 6, 2024
23a1a63
[Console] Add ability to schedule alarm signals and a `console.alarm`…
HypeMC Sep 17, 2024
de23257
CS: clean some whitespaces/indentation
keradus Oct 6, 2024
a97129d
Add `$seconds` to `keepalive` methods
valtzu Oct 13, 2024
8f6d3ec
Reduce common control flows
alexandre-daubois Oct 14, 2024
de74db6
Remove always true/false occurrences
alexandre-daubois Oct 18, 2024
c32691c
Don't use `die()` in PHPT `--SKIPIF--`
staabm Oct 27, 2024
3fda7e5
Merge branch '7.1' into 7.2
nicolas-grekas Nov 5, 2024
23c8aae
Merge branch '7.1' into 7.2
nicolas-grekas Nov 6, 2024
13189ef
Merge branch '7.1' into 7.2
xabbuh Dec 7, 2024
799445d
fix risky test that doesn't perform any assertions
xabbuh Dec 7, 2024
722fa7c
Merge branch '6.4' into 7.2
xabbuh Dec 9, 2024
fefcc18
[Console] Fix tests
chalasr Dec 11, 2024
759bdb4
Merge branch 'symfony:7.2' into patch-1
norbertosus Jan 15, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"image": "mcr.microsoft.com/devcontainers/universal:2",
"features": {
}
}
118 changes: 83 additions & 35 deletions Application.php

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
CHANGELOG
=========

7.2
---

* Add support for `FORCE_COLOR` environment variable
* Add `verbosity` argument to `mustRun` process helper method
* [BC BREAK] Add silent verbosity (`--silent`/`SHELL_VERBOSITY=-2`) to suppress all output, including errors
* Add `OutputInterface::isSilent()`, `Output::isSilent()`, `OutputStyle::isSilent()` methods
* Add a configurable finished indicator to the progress indicator to show that the progress is finished
* Add ability to schedule alarm signals and a `ConsoleAlarmEvent`

7.1
---

Expand Down
12 changes: 5 additions & 7 deletions CI/GithubActionReporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
*/
class GithubActionReporter
{
private OutputInterface $output;

/**
* @see https://github.com/actions/toolkit/blob/5e5e1b7aacba68a53836a34db4a288c3c1c1585b/packages/core/src/command.ts#L80-L85
*/
Expand All @@ -42,9 +40,9 @@ class GithubActionReporter
',' => '%2C',
];

public function __construct(OutputInterface $output)
{
$this->output = $output;
public function __construct(
private OutputInterface $output,
) {
}

public static function isGithubActionEnvironment(): bool
Expand Down Expand Up @@ -89,11 +87,11 @@ private function log(string $type, string $message, ?string $file = null, ?int $

if (!$file) {
// No file provided, output the message solely:
$this->output->writeln(sprintf('::%s::%s', $type, $message));
$this->output->writeln(\sprintf('::%s::%s', $type, $message));

return;
}

$this->output->writeln(sprintf('::%s file=%s,line=%s,col=%s::%s', $type, strtr($file, self::ESCAPED_PROPERTIES), strtr($line ?? 1, self::ESCAPED_PROPERTIES), strtr($col ?? 0, self::ESCAPED_PROPERTIES), $message));
$this->output->writeln(\sprintf('::%s file=%s,line=%s,col=%s::%s', $type, strtr($file, self::ESCAPED_PROPERTIES), strtr($line ?? 1, self::ESCAPED_PROPERTIES), strtr($col ?? 0, self::ESCAPED_PROPERTIES), $message));
}
}
8 changes: 4 additions & 4 deletions Color.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function __construct(string $foreground = '', string $background = '', ar

foreach ($options as $option) {
if (!isset(self::AVAILABLE_OPTIONS[$option])) {
throw new InvalidArgumentException(sprintf('Invalid option specified: "%s". Expected one of (%s).', $option, implode(', ', array_keys(self::AVAILABLE_OPTIONS))));
throw new InvalidArgumentException(\sprintf('Invalid option specified: "%s". Expected one of (%s).', $option, implode(', ', array_keys(self::AVAILABLE_OPTIONS))));
}

$this->options[$option] = self::AVAILABLE_OPTIONS[$option];
Expand Down Expand Up @@ -88,7 +88,7 @@ public function set(): string
return '';
}

return sprintf("\033[%sm", implode(';', $setCodes));
return \sprintf("\033[%sm", implode(';', $setCodes));
}

public function unset(): string
Expand All @@ -107,7 +107,7 @@ public function unset(): string
return '';
}

return sprintf("\033[%sm", implode(';', $unsetCodes));
return \sprintf("\033[%sm", implode(';', $unsetCodes));
}

private function parseColor(string $color, bool $background = false): string
Expand All @@ -128,6 +128,6 @@ private function parseColor(string $color, bool $background = false): string
return ($background ? '10' : '9').self::BRIGHT_COLORS[$color];
}

throw new InvalidArgumentException(sprintf('Invalid "%s" color; expected one of (%s).', $color, implode(', ', array_merge(array_keys(self::COLORS), array_keys(self::BRIGHT_COLORS)))));
throw new InvalidArgumentException(\sprintf('Invalid "%s" color; expected one of (%s).', $color, implode(', ', array_merge(array_keys(self::COLORS), array_keys(self::BRIGHT_COLORS)))));
}
}
10 changes: 5 additions & 5 deletions Command/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ public function getDefinition(): InputDefinition
*/
public function getNativeDefinition(): InputDefinition
{
return $this->definition ?? throw new LogicException(sprintf('Command class "%s" is not correctly initialized. You probably forgot to call the parent constructor.', static::class));
return $this->definition ?? throw new LogicException(\sprintf('Command class "%s" is not correctly initialized. You probably forgot to call the parent constructor.', static::class));
}

/**
Expand Down Expand Up @@ -603,7 +603,7 @@ public function getSynopsis(bool $short = false): string
$key = $short ? 'short' : 'long';

if (!isset($this->synopsis[$key])) {
$this->synopsis[$key] = trim(sprintf('%s %s', $this->name, $this->definition->getSynopsis($short)));
$this->synopsis[$key] = trim(\sprintf('%s %s', $this->name, $this->definition->getSynopsis($short)));
}

return $this->synopsis[$key];
Expand All @@ -617,7 +617,7 @@ public function getSynopsis(bool $short = false): string
public function addUsage(string $usage): static
{
if (!str_starts_with($usage, $this->name)) {
$usage = sprintf('%s %s', $this->name, $usage);
$usage = \sprintf('%s %s', $this->name, $usage);
}

$this->usages[] = $usage;
Expand All @@ -642,7 +642,7 @@ public function getUsages(): array
public function getHelper(string $name): HelperInterface
{
if (null === $this->helperSet) {
throw new LogicException(sprintf('Cannot retrieve helper "%s" because there is no HelperSet defined. Did you forget to add your command to the application or to set the application on the command using the setApplication() method? You can also set the HelperSet directly using the setHelperSet() method.', $name));
throw new LogicException(\sprintf('Cannot retrieve helper "%s" because there is no HelperSet defined. Did you forget to add your command to the application or to set the application on the command using the setApplication() method? You can also set the HelperSet directly using the setHelperSet() method.', $name));
}

return $this->helperSet->get($name);
Expand All @@ -658,7 +658,7 @@ public function getHelper(string $name): HelperInterface
private function validateName(string $name): void
{
if (!preg_match('/^[^\:]++(\:[^\:]++)*$/', $name)) {
throw new InvalidArgumentException(sprintf('Command name "%s" is invalid.', $name));
throw new InvalidArgumentException(\sprintf('Command name "%s" is invalid.', $name));
}
}
}
12 changes: 6 additions & 6 deletions Command/CompleteCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
// "symfony" must be kept for compat with the shell scripts generated by Symfony Console 5.4 - 6.1
$version = $input->getOption('symfony') ? '1' : $input->getOption('api-version');
if ($version && version_compare($version, self::COMPLETION_API_VERSION, '<')) {
$message = sprintf('Completion script version is not supported ("%s" given, ">=%s" required).', $version, self::COMPLETION_API_VERSION);
$message = \sprintf('Completion script version is not supported ("%s" given, ">=%s" required).', $version, self::COMPLETION_API_VERSION);
$this->log($message);

$output->writeln($message.' Install the Symfony completion script again by using the "completion" command.');
Expand All @@ -88,7 +88,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
}

if (!$completionOutput = $this->completionOutputs[$shell] ?? false) {
throw new \RuntimeException(sprintf('Shell completion is not supported for your shell: "%s" (supported: "%s").', $shell, implode('", "', array_keys($this->completionOutputs))));
throw new \RuntimeException(\sprintf('Shell completion is not supported for your shell: "%s" (supported: "%s").', $shell, implode('", "', array_keys($this->completionOutputs))));
}

$completionInput = $this->createCompletionInput($input);
Expand All @@ -98,13 +98,13 @@ protected function execute(InputInterface $input, OutputInterface $output): int
'',
'<comment>'.date('Y-m-d H:i:s').'</>',
'<info>Input:</> <comment>("|" indicates the cursor position)</>',
' '.(string) $completionInput,
' '.$completionInput,
'<info>Command:</>',
' '.(string) implode(' ', $_SERVER['argv']),
' '.implode(' ', $_SERVER['argv']),
'<info>Messages:</>',
]);

$command = $this->findCommand($completionInput, $output);
$command = $this->findCommand($completionInput);
if (null === $command) {
$this->log(' No command found, completing using the Application class.');

Expand Down Expand Up @@ -185,7 +185,7 @@ private function createCompletionInput(InputInterface $input): CompletionInput
return $completionInput;
}

private function findCommand(CompletionInput $completionInput, OutputInterface $output): ?Command
private function findCommand(CompletionInput $completionInput): ?Command
{
try {
$inputName = $completionInput->getFirstArgument();
Expand Down
6 changes: 3 additions & 3 deletions Command/DumpCompletionCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ protected function configure(): void
$commandName = basename($fullCommand);
$fullCommand = @realpath($fullCommand) ?: $fullCommand;

$shell = $this->guessShell();
$shell = self::guessShell();
[$rcFile, $completionFile] = match ($shell) {
'fish' => ['~/.config/fish/config.fish', "/etc/fish/completions/$commandName.fish"],
'zsh' => ['~/.zshrc', '$fpath[1]/_'.$commandName],
Expand Down Expand Up @@ -98,9 +98,9 @@ protected function execute(InputInterface $input, OutputInterface $output): int
$output = $output->getErrorOutput();
}
if ($shell) {
$output->writeln(sprintf('<error>Detected shell "%s", which is not supported by Symfony shell completion (supported shells: "%s").</>', $shell, implode('", "', $supportedShells)));
$output->writeln(\sprintf('<error>Detected shell "%s", which is not supported by Symfony shell completion (supported shells: "%s").</>', $shell, implode('", "', $supportedShells)));
} else {
$output->writeln(sprintf('<error>Shell not detected, Symfony shell completion only supports "%s").</>', implode('", "', $supportedShells)));
$output->writeln(\sprintf('<error>Shell not detected, Symfony shell completion only supports "%s").</>', implode('", "', $supportedShells)));
}

return 2;
Expand Down
2 changes: 1 addition & 1 deletion CommandLoader/ContainerCommandLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public function __construct(
public function get(string $name): Command
{
if (!$this->has($name)) {
throw new CommandNotFoundException(sprintf('Command "%s" does not exist.', $name));
throw new CommandNotFoundException(\sprintf('Command "%s" does not exist.', $name));
}

return $this->container->get($this->commandMap[$name]);
Expand Down
2 changes: 1 addition & 1 deletion CommandLoader/FactoryCommandLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public function has(string $name): bool
public function get(string $name): Command
{
if (!isset($this->factories[$name])) {
throw new CommandNotFoundException(sprintf('Command "%s" does not exist.', $name));
throw new CommandNotFoundException(\sprintf('Command "%s" does not exist.', $name));
}

$factory = $this->factories[$name];
Expand Down
6 changes: 3 additions & 3 deletions Completion/CompletionInput.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,13 +123,13 @@ public function bind(InputDefinition $definition): void
if ($this->currentIndex >= \count($this->tokens)) {
if (!isset($this->arguments[$argumentName]) || $this->definition->getArgument($argumentName)->isArray()) {
$this->completionName = $argumentName;
$this->completionValue = '';
} else {
// we've reached the end
$this->completionType = self::TYPE_NONE;
$this->completionName = null;
$this->completionValue = '';
}

$this->completionValue = '';
}
}

Expand Down Expand Up @@ -226,7 +226,7 @@ private function isCursorFree(): bool
return $this->currentIndex >= $nrOfTokens;
}

public function __toString()
public function __toString(): string
{
$str = '';
foreach ($this->tokens as $i => $token) {
Expand Down
14 changes: 7 additions & 7 deletions Cursor.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function __construct(
*/
public function moveUp(int $lines = 1): static
{
$this->output->write(sprintf("\x1b[%dA", $lines));
$this->output->write(\sprintf("\x1b[%dA", $lines));

return $this;
}
Expand All @@ -46,7 +46,7 @@ public function moveUp(int $lines = 1): static
*/
public function moveDown(int $lines = 1): static
{
$this->output->write(sprintf("\x1b[%dB", $lines));
$this->output->write(\sprintf("\x1b[%dB", $lines));

return $this;
}
Expand All @@ -56,7 +56,7 @@ public function moveDown(int $lines = 1): static
*/
public function moveRight(int $columns = 1): static
{
$this->output->write(sprintf("\x1b[%dC", $columns));
$this->output->write(\sprintf("\x1b[%dC", $columns));

return $this;
}
Expand All @@ -66,7 +66,7 @@ public function moveRight(int $columns = 1): static
*/
public function moveLeft(int $columns = 1): static
{
$this->output->write(sprintf("\x1b[%dD", $columns));
$this->output->write(\sprintf("\x1b[%dD", $columns));

return $this;
}
Expand All @@ -76,7 +76,7 @@ public function moveLeft(int $columns = 1): static
*/
public function moveToColumn(int $column): static
{
$this->output->write(sprintf("\x1b[%dG", $column));
$this->output->write(\sprintf("\x1b[%dG", $column));

return $this;
}
Expand All @@ -86,7 +86,7 @@ public function moveToColumn(int $column): static
*/
public function moveToPosition(int $column, int $row): static
{
$this->output->write(sprintf("\x1b[%d;%dH", $row + 1, $column));
$this->output->write(\sprintf("\x1b[%d;%dH", $row + 1, $column));

return $this;
}
Expand Down Expand Up @@ -195,7 +195,7 @@ public function getCurrentPosition(): array

$code = trim(fread($this->input, 1024));

shell_exec(sprintf('stty %s', $sttyMode));
shell_exec(\sprintf('stty %s', $sttyMode));

sscanf($code, "\033[%d;%dR", $row, $col);

Expand Down
6 changes: 3 additions & 3 deletions DataCollector/CommandDataCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public function getCommand(): array
public function getInterruptedBySignal(): ?string
{
if (isset($this->data['interrupted_by_signal'])) {
return sprintf('%s (%d)', SignalMap::getSignalName($this->data['interrupted_by_signal']), $this->data['interrupted_by_signal']);
return \sprintf('%s (%d)', SignalMap::getSignalName($this->data['interrupted_by_signal']), $this->data['interrupted_by_signal']);
}

return null;
Expand Down Expand Up @@ -204,15 +204,15 @@ public function getInteractiveInputs(): array
public function getSignalable(): array
{
return array_map(
static fn (int $signal): string => sprintf('%s (%d)', SignalMap::getSignalName($signal), $signal),
static fn (int $signal): string => \sprintf('%s (%d)', SignalMap::getSignalName($signal), $signal),
$this->data['signalable']
);
}

public function getHandledSignals(): array
{
$keys = array_map(
static fn (int $signal): string => sprintf('%s (%d)', SignalMap::getSignalName($signal), $signal),
static fn (int $signal): string => \sprintf('%s (%d)', SignalMap::getSignalName($signal), $signal),
array_keys($this->data['handled_signals'])
);

Expand Down
10 changes: 5 additions & 5 deletions DependencyInjection/AddConsoleCommandPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ public function process(ContainerBuilder $container): void
$aliases = $tags[0]['command'];
} else {
if (!$r = $container->getReflectionClass($class)) {
throw new InvalidArgumentException(sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id));
throw new InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id));
}
if (!$r->isSubclassOf(Command::class)) {
throw new InvalidArgumentException(sprintf('The service "%s" tagged "%s" must be a subclass of "%s".', $id, 'console.command', Command::class));
throw new InvalidArgumentException(\sprintf('The service "%s" tagged "%s" must be a subclass of "%s".', $id, 'console.command', Command::class));
}
$aliases = str_replace('%', '%%', $class::getDefaultName() ?? '');
}

$aliases = explode('|', $aliases ?? '');
$aliases = explode('|', $aliases);
$commandName = array_shift($aliases);

if ($isHidden = '' === $commandName) {
Expand Down Expand Up @@ -102,10 +102,10 @@ public function process(ContainerBuilder $container): void

if (!$description) {
if (!$r = $container->getReflectionClass($class)) {
throw new InvalidArgumentException(sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id));
throw new InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id));
}
if (!$r->isSubclassOf(Command::class)) {
throw new InvalidArgumentException(sprintf('The service "%s" tagged "%s" must be a subclass of "%s".', $id, 'console.command', Command::class));
throw new InvalidArgumentException(\sprintf('The service "%s" tagged "%s" must be a subclass of "%s".', $id, 'console.command', Command::class));
}
$description = str_replace('%', '%%', $class::getDefaultDescription() ?? '');
}
Expand Down
2 changes: 1 addition & 1 deletion Descriptor/ApplicationDescription.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public function getCommands(): array
public function getCommand(string $name): Command
{
if (!isset($this->commands[$name]) && !isset($this->aliases[$name])) {
throw new CommandNotFoundException(sprintf('Command "%s" does not exist.', $name));
throw new CommandNotFoundException(\sprintf('Command "%s" does not exist.', $name));
}

return $this->commands[$name] ?? $this->aliases[$name];
Expand Down
2 changes: 1 addition & 1 deletion Descriptor/Descriptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function describe(OutputInterface $output, object $object, array $options
$object instanceof InputDefinition => $this->describeInputDefinition($object, $options),
$object instanceof Command => $this->describeCommand($object, $options),
$object instanceof Application => $this->describeApplication($object, $options),
default => throw new InvalidArgumentException(sprintf('Object of type "%s" is not describable.', get_debug_type($object))),
default => throw new InvalidArgumentException(\sprintf('Object of type "%s" is not describable.', get_debug_type($object))),
};
}

Expand Down
Loading