Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 1m14s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 1m12s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 1m7s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 1m19s
CI / PHP 8.3 / mysql:8.0 (pull_request) Successful in 1m32s
CI / PHP 8.4 / mysql:8.0 (pull_request) Successful in 1m22s
CI / PHP 8.4 / mysql:8.4 (pull_request) Successful in 1m32s
CI / PHP 8.3 / mysql:8.4 (pull_request) Successful in 1m35s
CI / Build-Artefakte aktuell (pull_request) Failing after 1m7s
- Laravel 13 mit Filament 5 (Admin), Inertia 3 + Vue 3 + Vuetify 4 (Material 3) - Anmeldung über Fortify (Login, Passwort vergessen/ändern), keine Selbstregistrierung - Profil mit Profilbild (WebP in festen Größen), Personenseiten, Header mit Avatar-Menü - Material-3-Farbschema aus der Primärfarbe, hell/dunkel/System pro Person - Basis-Branding (Portalname, Logo, Primärfarbe) im Admin unter „Erscheinungsbild“ - Benutzerverwaltung im Admin, Zugang vorläufig über is_admin - vendor/ (ohne Dev-Pakete) und Frontend-Build mitversioniert, Dev-Pakete in vendor-dev/ - PHPUnit-Tests gegen MySQL/MariaDB, Forgejo-CI-Matrix, Docker-Entwicklungsumgebung - VERSION, CHANGELOG.md und CONTRIBUTING.md mit Release-Ablauf Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
76 lines
2.5 KiB
PHP
76 lines
2.5 KiB
PHP
<?php
|
|
|
|
/*
|
|
* This file is part of the Symfony package.
|
|
*
|
|
* (c) Fabien Potencier <fabien@symfony.com>
|
|
*
|
|
* For the full copyright and license information, please view the LICENSE
|
|
* file that was distributed with this source code.
|
|
*/
|
|
|
|
namespace Symfony\Component\Console\Command;
|
|
|
|
use Symfony\Component\Console\Descriptor\ApplicationDescription;
|
|
use Symfony\Component\Console\Helper\DescriptorHelper;
|
|
use Symfony\Component\Console\Input\InputArgument;
|
|
use Symfony\Component\Console\Input\InputInterface;
|
|
use Symfony\Component\Console\Input\InputOption;
|
|
use Symfony\Component\Console\Output\OutputInterface;
|
|
|
|
/**
|
|
* HelpCommand displays the help for a given command.
|
|
*
|
|
* @author Fabien Potencier <fabien@symfony.com>
|
|
*/
|
|
class HelpCommand extends Command
|
|
{
|
|
private Command $command;
|
|
|
|
protected function configure(): void
|
|
{
|
|
$this->ignoreValidationErrors();
|
|
|
|
$this
|
|
->setName('help')
|
|
->setDefinition([
|
|
new InputArgument('command_name', InputArgument::OPTIONAL, 'The command name', 'help', fn () => array_keys((new ApplicationDescription($this->getApplication()))->getCommands())),
|
|
new InputOption('format', null, InputOption::VALUE_REQUIRED, 'The output format (txt, xml, json, or md)', 'txt', static fn () => (new DescriptorHelper())->getFormats()),
|
|
new InputOption('raw', null, InputOption::VALUE_NONE, 'To output raw command help'),
|
|
])
|
|
->setDescription('Display help for a command')
|
|
->setHelp(<<<'EOF'
|
|
The <info>%command.name%</info> command displays help for a given command:
|
|
|
|
<info>%command.full_name% list</info>
|
|
|
|
You can also output the help in other formats by using the <info>--format</info> option:
|
|
|
|
<info>%command.full_name% --format=xml list</info>
|
|
|
|
To display the list of available commands, please use the <info>list</info> command.
|
|
EOF
|
|
)
|
|
;
|
|
}
|
|
|
|
public function setCommand(Command $command): void
|
|
{
|
|
$this->command = $command;
|
|
}
|
|
|
|
protected function execute(InputInterface $input, OutputInterface $output): int
|
|
{
|
|
$this->command ??= $this->getApplication()->find($input->getArgument('command_name'));
|
|
|
|
$helper = new DescriptorHelper();
|
|
$helper->describe($output, $this->command, [
|
|
'format' => $input->getOption('format'),
|
|
'raw_text' => $input->getOption('raw'),
|
|
]);
|
|
|
|
unset($this->command);
|
|
|
|
return 0;
|
|
}
|
|
}
|