test.js   A
last analyzed

Complexity

Total Complexity 2
Complexity/F 0

Size

Lines of Code 16
Function Count 0

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 9
mnd 2
bc 2
fnc 0
dl 0
loc 16
bpm 0
cpm 0
noi 0
c 0
b 0
f 0
rs 10
1
const path              = require('path');
2
3
const current_path      = process.cwd() + '/';
4
5
const plugin_name       = process.argv.length >= 2 ? process.argv[2] : false;
6
7
if( ! plugin_name ){
8
    console.error( '\x1b[31m%s\x1b[0m', 'Error: You must enter a plugin name');
9
    return;
10
}
11
const Plugin_Generator  = require( path.join( current_path, 'inc', 'Plugin_Generator.js' ) );
12
13
const plugin            = new Plugin_Generator( plugin_name );
14
15
16
plugin.generate();
17
//End of file
18