Micro-PHP /
plugin-dto
| 1 | <?php |
||
| 2 | |||
| 3 | declare(strict_types=1); |
||
| 4 | |||
| 5 | /* |
||
| 6 | * This file is part of the Micro framework package. |
||
| 7 | * |
||
| 8 | * (c) Stanislau Komar <[email protected]> |
||
| 9 | * |
||
| 10 | * For the full copyright and license information, please view the LICENSE |
||
| 11 | * file that was distributed with this source code. |
||
| 12 | */ |
||
| 13 | |||
| 14 | namespace Micro\Plugin\DTO\Console; |
||
| 15 | |||
| 16 | use Micro\Plugin\DTO\Facade\DTOFacadeInterface; |
||
| 17 | use Symfony\Component\Console\Command\Command; |
||
|
0 ignored issues
–
show
|
|||
| 18 | use Symfony\Component\Console\Input\InputInterface; |
||
| 19 | use Symfony\Component\Console\Output\OutputInterface; |
||
| 20 | |||
| 21 | class GenerateDTOCommand extends Command |
||
| 22 | { |
||
| 23 | protected const HELP = 'Generate DTO classes.'; |
||
| 24 | protected static $defaultName = 'micro:dto:generate'; |
||
| 25 | |||
| 26 | 2 | public function __construct( |
|
| 27 | private readonly DTOFacadeInterface $DTOFacade |
||
| 28 | ) { |
||
| 29 | 2 | parent::__construct(self::$defaultName); |
|
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * {@inheritDoc} |
||
| 34 | */ |
||
| 35 | 2 | protected function execute(InputInterface $input, OutputInterface $output): int |
|
| 36 | { |
||
| 37 | 2 | $output->writeln('<info> Generate DTO classes... </info>'); |
|
| 38 | try { |
||
| 39 | 2 | $this->DTOFacade->generate(); |
|
| 40 | 1 | $output->writeln('<info> Success!</info>'); |
|
| 41 | 1 | } catch (\Throwable $e) { |
|
| 42 | 1 | $output->writeln(sprintf('<error> %s </error>', $e->getMessage())); |
|
| 43 | |||
| 44 | 1 | throw $e; |
|
| 45 | } |
||
| 46 | |||
| 47 | 1 | return Command::SUCCESS; |
|
| 48 | } |
||
| 49 | } |
||
| 50 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths