Skip to content

Releases: davahome/console

Added support for symfony/console >=3.0 <6.0

Choose a tag to compare

@thedava thedava released this 25 Sep 11:20

Extended support for more Versions of symfony/console.

All Versions between 3.0 and 6.0 are now supported

Fixed ProgressBar PHP Fatal Error

Choose a tag to compare

@thedava thedava released this 01 Jan 05:46

Due to changes in symfony/console it's not longer possible to inherit from the ProgressBar class. This results in some major changes.

To improve readability all classes are shortened by the following scheme:

DavaHome\Console\AbstractCommand    -> DH\AbstractCommand
DavaHome\Console\Helper\ProgressBar -> DH\ProgressBar
DavaHome\Console\Helper\Table       -> DH\Table

Symfony\Component\Console\Helper\ProgressBar -> SF\ProgressBar
Symfony\Component\Console\Helper\Table       -> SF\Table
  • DH\AbstractCommand::createProgressBar doesn't create a DH\ProgressBar instance any more

    • It will create a SF\ProgressBar instance now
    • This leads to a breaking change. Usages like $progressBar::FORMAT_DEBUG will not work any more
    • The reason is that SF\ProgressBar is final now and therefore suppresses inheritance
  • DH\AbstractCommand::createTable doesn't create a DH\Table instance any more

    • It will create a SF\Table instance now
    • This leads to a breaking change. Usages like $table::STYLE_COMPACT will not work any more
    • This change was made to keep consistency to the ProgressBar
  • DH\ProgressBar was renamed to DavaHome\Console\Helper\ProgressBarOptions

    • This class only contains constants and doesn't provide any functionality any more
  • DH\Table was renamed to DavaHome\Console\Helper\TableOptions

    • This class only contains constants and doesn't provide any functionality any more

Added Table

Choose a tag to compare

@thedava thedava released this 17 Oct 22:13

Added Table class (with STYLE-constants)

Example:

use \DavaHome\Console\Helper\Table;
$table = new Table($output);
$table->setStyle(Table::STYLE_COMPACT);

Added createTable-Method for commands

use \DavaHome\Console\Command\AbstractCommand;

class Command extends AbstractCommand
{
    public function execute($input, $output)
    {
        $table = $this->createTable($output);
    }
}

Added ProgressBar

Choose a tag to compare

@thedava thedava released this 13 Oct 12:49

Added ProgressBar class (with FORMAT-constants)

Example:

use \DavaHome\Console\Helper\ProgressBar;
$progressBar = new ProgressBar($output);
$progressBar->setFormat(ProgressBar::FORMAT_DEBUG);

Added createProgressBar-Method for commands

use \DavaHome\Console\Command\AbstractCommand;

class Command extends AbstractCommand
{
    public function execute($input, $output)
    {
        $progressBar = $this->createProgressBar($output);
    }
}

Added getErrorOutput method

Choose a tag to compare

@thedava thedava released this 23 Jul 19:00
1.0.2

Update AbstractCommand.php

1.0.1

Choose a tag to compare

@thedava thedava released this 24 May 14:19
Fixed namespace

1.0

1.0

Choose a tag to compare

@thedava thedava released this 24 May 14:14
Initial commit