| Conditions | 1 |
| Paths | 1 |
| Total Lines | 24 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 19 | static function __help () { |
||
| 20 | $version = file_get_json(__DIR__.'/../meta.json')['version']; |
||
| 21 | $help = <<<HELP |
||
| 22 | %gCleverStyle CMS%n version %y$version%n, CLI interface%n |
||
| 23 | |||
| 24 | %yUsage:%n |
||
| 25 | [method:]path [arguments] |
||
| 26 | |||
| 27 | %yUniversal methods:%n |
||
| 28 | %gcli%n Prints all cli paths and methods available for specified path |
||
| 29 | %ghelp%n Displays help for module or path (should be provided by developer, otherwise will fallback to %gcli%n) |
||
| 30 | |||
| 31 | %yExamples%n |
||
| 32 | Print all paths and methods available in the whole system: |
||
| 33 | %g./cli cli:%n |
||
| 34 | Print all paths and method available in System module: |
||
| 35 | %g./cli cli:System%n |
||
| 36 | Print all paths and method available in System module, admin sub-path: |
||
| 37 | %g./cli cli:System/admin%n |
||
| 38 | Print help information (this message) for System module: |
||
| 39 | %g./cli help:System%n |
||
| 40 | HELP; |
||
| 41 | line($help); |
||
| 42 | } |
||
| 43 | } |
||
| 44 |