Extend Marwa\Framework\Console\AbstractCommand when you want command classes to access the application base path, config repository, logger, and service container through helper methods.
final class CleanupCommand extends AbstractCommand
{
protected function execute(InputInterface $input, OutputInterface $output): int
{
$this->logger()->info('Cleanup started');
return Command::SUCCESS;
}
}
Application::registerCommand()config/console.phpdiscover rules for PSR-4 command directoriesConsoleCommandConfiguratorInterface implementationConsoleKernel attempts to register marwa-db console commands automatically when that package exposes a compatible console configurator or command namespace. The integration is optional and safely ignored when the package is not installed.
Framework-provided scaffolding stubs now live under src/Stubs/. If a consuming app wants custom AI helper stubs, override console.stubsPath in config/console.php.