Version   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 12
ccs 0
cts 6
cp 0
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A execute() 0 3 1
A configure() 0 5 1
1
<?php
2
// +----------------------------------------------------------------------
3
// | ThinkPHP [ WE CAN DO IT JUST THINK IT ]
4
// +----------------------------------------------------------------------
5
// | Copyright (c) 2006-2016 http://thinkphp.cn All rights reserved.
6
// +----------------------------------------------------------------------
7
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
8
// +----------------------------------------------------------------------
9
// | Author: liu21st <[email protected]>
10
// +----------------------------------------------------------------------
11
declare (strict_types = 1);
12
13
namespace think\console\command;
14
15
use think\console\Command;
16
use think\console\Input;
17
use think\console\Output;
18
19
class Version extends Command
20
{
21
    protected function configure()
22
    {
23
        // 指令配置
24
        $this->setName('version')
25
            ->setDescription('show thinkphp framework version');
26
    }
27
28
    protected function execute(Input $input, Output $output)
29
    {
30
        $output->writeln('v' . $this->app->version());
31
    }
32
33
}
34