Completed
Push — master ( 926f1e...80db42 )
by Anton
10:25 queued 07:09
created

SeedRunCommand::configure()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 15
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 15
ccs 7
cts 7
cp 1
rs 9.4285
c 1
b 0
f 0
cc 1
eloc 7
nc 1
nop 0
crap 1
1
<?php
2
/**
3
 * @copyright Bluz PHP Team
4
 * @link https://github.com/bluzphp/bluzman
5
 */
6
7
namespace Bluzman\Command\Db;
8
9
use Bluzman\Input\InputArgument;
10
11
/**
12
 * Run seed command
13
 *
14
 * @package  Bluzman\Command\Db
15
 * @author   Anton Shevchuk
16
 */
17
class SeedRunCommand extends AbstractDbCommand
18
{
19
    /**
20
     * Command configuration
21
     */
22 14
    protected function configure()
23
    {
24
        $this
25
            // the name of the command (the part after "bin/bluzman")
26 14
            ->setName('db:seed:run')
27
            // the short description shown while running "php bin/bluzman list"
28 14
            ->setDescription('Run seed file(s)')
29
            // the full command description shown when running the command with
30
            // the "--help" option
31 14
            ->setHelp('This command is shorthand to phinx tool')
32
        ;
33
34 14
        $name = new InputArgument('--seed', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, 'Seed name(s) to run');
35 14
        $this->getDefinition()->addArgument($name);
36 14
    }
37
}
38