Refactored command outputs
This commit is contained in:
parent
07b2e434a5
commit
580f7ae28a
3 changed files with 23 additions and 21 deletions
|
|
@ -45,20 +45,9 @@ EOT
|
|||
* @throws \InvalidArgumentException When the target directory does not exist
|
||||
*/
|
||||
protected function execute(InputInterface $input, OutputInterface $output)
|
||||
{
|
||||
{
|
||||
$this->callPhing('diff');
|
||||
|
||||
foreach (explode("\n", $this->buffer) as $line) {
|
||||
if (false !== strpos($line, '[propel-sql-diff]')) {
|
||||
$arr = preg_split('#\[propel-sql-diff\] #', $line);
|
||||
$info = $arr[1];
|
||||
|
||||
if ('"' === $info[0]) {
|
||||
$info = sprintf('<info>%s</info>', $info);
|
||||
}
|
||||
|
||||
$output->writeln($info);
|
||||
}
|
||||
}
|
||||
$this->summary($output, 'propel-sql-diff');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue