src/Command/PbjcApplication.php
<?php
namespace Gdbots\Pbjc\Command;
use Symfony\Component\Console\Application;
use Symfony\Component\Console\Input\InputInterface;
class PbjcApplication extends Application
{
/**
* {@inheritdoc}
*/
protected function getCommandName(InputInterface $input)
{
return 'pbjc';
}
/**
* {@inheritdoc}
*/
protected function getDefaultCommands()
{
$defaultCommands = parent::getDefaultCommands();
$defaultCommands[] = new CompileCommand();
return $defaultCommands;
}
/**
* {@inheritdoc}
*/
public function getDefinition()
{
$inputDefinition = parent::getDefinition();
// clear out the normal first argument, which is the command name
$inputDefinition->setArguments();
return $inputDefinition;
}
}