-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcody.php
executable file
·55 lines (40 loc) · 1.31 KB
/
cody.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
use Markatom\Cody\Configuration;
use Markatom\Cody\File;
use Markatom\Cody\Finder;
use Markatom\Cody\Output;
use Markatom\Cody\Runner;
require_once __DIR__ . '/vendor/autoload.php';
require_once __DIR__ . '/vendor/markatom/watchers/src/Boolean.php';
require_once __DIR__ . '/vendor/markatom/watchers/src/Keyword.php';
require_once __DIR__ . '/vendor/markatom/watchers/src/Naming.php';
require_once __DIR__ . '/vendor/markatom/watchers/src/Null.php';
$logo = <<<'END'
* *
|\_/|
/ - ^ \ CODY v0.1.0
~~o O~~ using cs.neon
\@/
END;
$help = <<<'END'
\033[1mUSAGE:
\033[1mcody\033[0m check [-h | --help] [-d | --details] [ -s | --summary] |
fix [-h | --help] [-d | --details] [ -s | --summary]
\033[1mCOMMANDS:\033[0m
\033[1mcheck\033[0m
Checks whether target source files contains violiation against defined
coding standards.
\033[1mfix\033[0m
Performs reformatting of target source files according to defined
coding standards.
\033[1mOPTIONS:\033[0m
\033[1m-h, --help\033[0m
Display help page.
\033[1m-d, --details\033[0m
Foo bar.
\033[1m-s, --summary\033[0m
Lorem ipsum dolor sit amet.
END;
echo $logo . PHP_EOL;
$runner = new Runner(new Configuration(new File('cs.neon')), new Finder, new Output(STDOUT, TRUE), TRUE);
$runner->run();