/** * Build a new custom command * * @param Task $task * @param string $name A name for the command */ public function __construct(Task $task, $name = null) { parent::__construct(); // Set Task $this->task = $task; $this->task->command = $this; // Set name $this->name = $name ?: $task->getSlug(); $this->name = 'deploy:' . $this->name; // Set description $this->setDescription($task->getDescription()); }
/** * Get the console command options. * * @return array */ protected function getOptions() { return array_merge(parent::getOptions(), array(array('list', 'L', InputOption::VALUE_NONE, 'Shows the available releases to rollback to'))); }
/** * Get the console command options. * * @return array */ protected function getOptions() { return array_merge(parent::getOptions(), array(array('migrate', 'm', InputOption::VALUE_NONE, 'Run the migrations'), array('seed', 's', InputOption::VALUE_NONE, 'Seed the database after migrating the database'))); }
/** * Get the console command options. * * @return array */ protected function getOptions() { return array_merge(parent::getOptions(), array(array('clean-all', null, InputOption::VALUE_NONE, 'Cleans up all non-current releases'))); }
/** * Get the console command options. * * @return array */ protected function getOptions() { return array_merge(parent::getOptions(), array(array('tests', 't', InputOption::VALUE_NONE, 'Runs the tests on deploy'), array('migrate', 'm', InputOption::VALUE_NONE, 'Run the migrations'), array('seed', 's', InputOption::VALUE_NONE, 'Seed the database (after migrating it if --migrate)'), array('clean-all', null, InputOption::VALUE_NONE, 'Cleanup all but the current release on deploy'))); }