-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated arguments for
diktat-cli
(#1860)
- `reporter` is optional now - `output` is required now when `reporter` is provided - renamed parameters are related to plain output - added a new type `PLAIN_GROUP_BY_FILE`
- Loading branch information
Showing
5 changed files
with
198 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
= _diktat-cli_, the command-line client for https://github.com/saveourtool/diktat[_diKTat_] | ||
:toc: | ||
|
||
[#features] | ||
== Features | ||
|
||
* Self-executable JAR in _UNIX Shell_ (requires installed _JAVA_) | ||
* BSD-compatible | ||
* Also works in Windows (_Git Bash_, _Cygwin_, or _MSys2_) via the dedicated _diktat.cmd_ | ||
* Can be used as a regular uber JAR | ||
[#usage] | ||
== Usage | ||
|
||
[source,bash] | ||
---- | ||
diktat [OPTION]... [FILE]... | ||
---- | ||
|
||
[#options] | ||
== Option summary | ||
|
||
.Options | ||
[cols="1,3"] | ||
|=== | ||
| Command-line switch | Meaning | ||
|
||
| `-c CONFIG`, `--config=CONFIG` | ||
| Specify the location of the YAML configuration file. By default, | ||
`diktat-analysis.yml` in the current directory is used. | ||
|
||
| `-m MODE`, `--mode MODE` | ||
| Mode of `diktat` controls that `diktat` fixes or | ||
only finds any deviations from the code style. | ||
|
||
| `-r REPORTER`, `--reporter=REPORTER` | ||
| The reporter to use to errors to `output`, one of: `plain`, `plain_group_by_file`, | ||
`json`, `sarif`, `checkstyle`, `html`. | ||
|
||
| `-o OUTPUT`, `--output=OUTPUT` | ||
| Redirect the reporter output to a file. | ||
Must be provided when the reporter is provided. | ||
|
||
| `--group-by-file` | ||
| A flag to group found errors by files. | ||
|
||
| `--color COLOR` | ||
| Colorize the output, one of: `BLACK`, `RED`, | ||
`GREEN`, `YELLOW`, `BLUE`, `MAGENTA`, `CYAN`, `LIGHT_GRAY`, | ||
`DARK_GRAY`, `LIGHT_RED`, `LIGHT_GREEN`, `LIGHT_YELLOW`, | ||
`LIGHT_BLUE`, `LIGHT_MAGENTA`, `LIGHT_CYAN`, `WHITE` | ||
|
||
| `-l`, `--log-level` | ||
| Control the log level. | ||
|
||
| `-h`, `--help` | ||
| Display the help text and exit. | ||
|
||
| `-l`, `--license` | ||
| Display the license and exit. | ||
|
||
| `-v`, `--verbose` | ||
|Enable the verbose output. | ||
|
||
| `-V`, `--version` | ||
|Output version information and exit. | ||
|=== | ||
|
||
[#exit-codes] | ||
== Exit codes | ||
|
||
.Exit codes | ||
[cols="1,3"] | ||
|=== | ||
| Exit code | Meaning | ||
|
||
| 0 | ||
| _diKTat_ found no errors in your code | ||
|
||
| 1 | ||
| _diKTat_ reported some errors in your code | ||
|
||
| 2 | ||
| The JVM was not found (probably, you need to set up the JVM explicitly, using | ||
the `JAVA_HOME` environment variable) | ||
|
||
| 3 | ||
| Incompatible _Bash_ version | ||
|=== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.