Passed
Push — develop ( 76f1bd...bca4a5 )
by Bjarn
01:40 queued 11s
created

src/commands/xdebugCommand.ts   A

Complexity

Total Complexity 1
Complexity/F 1

Size

Lines of Code 11
Function Count 1

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 9
dl 0
loc 11
rs 10
c 0
b 0
f 0
wmc 1
mnd 0
bc 0
fnc 1
bpm 0
cpm 1
noi 0

1 Function

Rating   Name   Duplication   Size   Complexity  
A xdebugCommand.ts ➔ installCommand 0 7 1
1
import commander from 'commander'
2
import XdebugController from '../controllers/xdebugController'
3
4
export default function installCommand(program: typeof commander) {
5
    return program
6
        .command('xdebug <status>')
7
        .description('Enable or disable the xdebug PHP extension. Use \'on\' or \'off\'.')
8
        .action((status: string) => {
9
            (new XdebugController()).execute(status).catch(err => console.log(err.message))
10
        })
11
}