1
0
mirror of https://github.com/kellyjonbrazil/jc.git synced 2025-06-21 00:19:42 +02:00

add long-options

This commit is contained in:
Kelly Brazil
2022-06-05 17:52:14 -07:00
parent da6c98826b
commit 15b58e3a6b
2 changed files with 30 additions and 36 deletions

View File

@ -251,24 +251,21 @@ option.
| ` --zipinfo` | `zipinfo` command parser | [📃](https://kellyjonbrazil.github.io/jc/docs/parsers/zipinfo) | | ` --zipinfo` | `zipinfo` command parser | [📃](https://kellyjonbrazil.github.io/jc/docs/parsers/zipinfo) |
### Options ### Options
- `-a` about `jc`. Prints information about `jc` and the parsers (in JSON or | Option | Description |
YAML, of course!) |-----------------------|--------------------------------------------------------------------------------------------------------------|
- `-C` force color output even when using pipes (overrides `-m` and the | `-a`, `--about` | about `jc`. Prints information about `jc` and the parsers (in JSON or YAML, of course!) |
`NO_COLOR` env variable) | `-C`, `--force_color` | force color output even when using pipes (overrides `-m` and the `NO_COLOR` env variable) |
- `-d` debug mode. Prints trace messages if parsing issues are encountered (use | `-d`, `--debug` | debug mode. Prints trace messages if parsing issues are encountered (use`-dd` for verbose debugging) |
`-dd` for verbose debugging) | `-h`, `--help` | help. Use `jc -h --parser_name` for parser documentation |
- `-h` help. Use `jc -h --parser_name` for parser documentation | `-m`, `--monochrome` | monochrome output |
- `-m` monochrome JSON output | `-p`, `--pretty` | pretty format the JSON output |
- `-p` pretty format the JSON output | `-q`, `--quiet` | quiet mode. Suppresses parser warning messages (use `-qq` to ignore streaming parser errors) |
- `-q` quiet mode. Suppresses parser warning messages (use `-qq` to ignore | `-r`, `--raw` | raw output. Provides more literal output, typically with string values and no additional semantic processing |
streaming parser errors) | `-u`, `--unbuffer` | unbuffer output |
- `-r` raw output. Provides a more literal JSON output, typically with string | `-v`, `--version` | version information |
values and no additional semantic processing | `-y`, `--yaml-out` | YAML output |
- `-u` unbuffer output | `-B`, `--bash-comp` | generate Bash shell completion script |
- `-v` version information | `-Z`, `--zsh-comp` | generate Zsh shell completion script |
- `-y` YAML output
- `-B` generate Bash shell completion script
- `-Z` generate Zsh shell completion script
### Exit Codes ### Exit Codes
Any fatal errors within `jc` will generate an exit code of `100`, otherwise the Any fatal errors within `jc` will generate an exit code of `100`, otherwise the

View File

@ -149,24 +149,21 @@ option.
| `{{ "{:>15}".format(parser.argument) }}` | {{ "{:<55}".format(parser.description) }} | {{ "{:<70}".format("[📃](https://kellyjonbrazil.github.io/jc/docs/parsers/" + parser.name + ")") }} |{% endfor %} | `{{ "{:>15}".format(parser.argument) }}` | {{ "{:<55}".format(parser.description) }} | {{ "{:<70}".format("[📃](https://kellyjonbrazil.github.io/jc/docs/parsers/" + parser.name + ")") }} |{% endfor %}
### Options ### Options
- `-a` about `jc`. Prints information about `jc` and the parsers (in JSON or | Option | Description |
YAML, of course!) |-----------------------|--------------------------------------------------------------------------------------------------------------|
- `-C` force color output even when using pipes (overrides `-m` and the | `-a`, `--about` | about `jc`. Prints information about `jc` and the parsers (in JSON or YAML, of course!) |
`NO_COLOR` env variable) | `-C`, `--force_color` | force color output even when using pipes (overrides `-m` and the `NO_COLOR` env variable) |
- `-d` debug mode. Prints trace messages if parsing issues are encountered (use | `-d`, `--debug` | debug mode. Prints trace messages if parsing issues are encountered (use`-dd` for verbose debugging) |
`-dd` for verbose debugging) | `-h`, `--help` | help. Use `jc -h --parser_name` for parser documentation |
- `-h` help. Use `jc -h --parser_name` for parser documentation | `-m`, `--monochrome` | monochrome output |
- `-m` monochrome JSON output | `-p`, `--pretty` | pretty format the JSON output |
- `-p` pretty format the JSON output | `-q`, `--quiet` | quiet mode. Suppresses parser warning messages (use `-qq` to ignore streaming parser errors) |
- `-q` quiet mode. Suppresses parser warning messages (use `-qq` to ignore | `-r`, `--raw` | raw output. Provides more literal output, typically with string values and no additional semantic processing |
streaming parser errors) | `-u`, `--unbuffer` | unbuffer output |
- `-r` raw output. Provides a more literal JSON output, typically with string | `-v`, `--version` | version information |
values and no additional semantic processing | `-y`, `--yaml-out` | YAML output |
- `-u` unbuffer output | `-B`, `--bash-comp` | generate Bash shell completion script |
- `-v` version information | `-Z`, `--zsh-comp` | generate Zsh shell completion script |
- `-y` YAML output
- `-B` generate Bash shell completion script
- `-Z` generate Zsh shell completion script
### Exit Codes ### Exit Codes
Any fatal errors within `jc` will generate an exit code of `100`, otherwise the Any fatal errors within `jc` will generate an exit code of `100`, otherwise the