Files
oficial/cli/setup/settings/commands.php

27 lines
916 B
PHP
Raw Permalink Normal View History

2024-08-27 14:50:45 -04:00
<?php
use Psr\Container\ContainerInterface;
2024-08-27 14:50:45 -04:00
return [
'commands' => function(ContainerInterface $container) {
$service = $container->get(Incoviba\Service\Commands::class);
if ($container->has('folders')) {
$folders = $container->get('folders');
if (is_array($folders)) {
if (array_key_exists('commands', $folders)) {
$service->baseCommandsPath = $folders['commands'];
}
} elseif (isset($folders->commands)) {
$service->baseCommandsPath = $folders->commands;
}
}
if ($container->has('skip_commands')) {
$service->skipCommands = $container->get('skip_commands');
}
if ($container->has('skipCommands')) {
$service->skipCommands = $container->get('skipCommands');
}
return $service->getCommandsList();
2024-08-27 14:50:45 -04:00
}
];