|
1 |
| -Argparse4j - The command line argument parser library |
2 |
| -===================================================== |
| 1 | +Argparse4j - The Java command-line argument parser library |
| 2 | +========================================================== |
3 | 3 |
|
4 |
| -The argparse4j is a command line argument parser library for Java |
5 |
| -based on Python's argparse. |
| 4 | +Argparse4j is a command line argument parser library for Java based |
| 5 | +on Python's |
| 6 | +`argparse <http://docs.python.org/3/library/argparse.html>`_ module. |
6 | 7 |
|
7 |
| -To see how to use argparse4j, see http://argparse4j.sourceforge.net/ |
| 8 | +Argparse4j is available in Maven central repository: |
| 9 | + |
| 10 | +.. code-block:: xml |
| 11 | +
|
| 12 | + <dependency> |
| 13 | + <groupId>net.sourceforge.argparse4j</groupId> |
| 14 | + <artifactId>argparse4j</artifactId> |
| 15 | + <version>0.3.2</version> |
| 16 | + </dependency> |
8 | 17 |
|
9 | 18 | There are still missing features which exist in argparse but not in
|
10 | 19 | argparse4j, but there are also new features which only exist in
|
11 | 20 | argparse4j.
|
12 | 21 |
|
13 |
| -Here is a summary of features: |
| 22 | +Here is summary of features: |
14 | 23 |
|
15 | 24 | * Supported positional arguments and optional arguments.
|
16 | 25 | * Variable number of arguments.
|
17 | 26 | * Generates well formatted line-wrapped help message.
|
18 | 27 | * Suggests optional arguments/sub-command if unrecognized
|
19 |
| - arguments/sub-command were given, e.g., ``unrecognized argument |
20 |
| - '--tpye'. Did you mean: --type``. |
| 28 | + arguments/sub-command were given, e.g.: |
| 29 | + |
| 30 | + .. code-block:: console |
| 31 | +
|
| 32 | + unrecognized argument '--tpye' |
| 33 | + Did you mean: |
| 34 | + --type |
| 35 | +
|
21 | 36 | * Takes into account East Asian Width ambiguous characters when
|
22 | 37 | line-wrap.
|
23 | 38 | * Sub-commands like, ``git add``.
|
24 | 39 | * Sub-command alias names, e.g., ``co`` for ``checkout``.
|
25 |
| -* Customizable option prefix characters, e.g., ``+f`` and ``/h``. |
| 40 | +* Customizable option prefix characters, e.g. ``+f`` and ``/h``. |
26 | 41 | * Print default values in help message.
|
27 | 42 | * Choice from given collection of values.
|
28 | 43 | * Type conversion from option strings.
|
29 |
| -* Can directly assign values into user defined classes using |
30 |
| - annotation. |
31 |
| -* Group arguments so that it will be printed in help message in more |
32 |
| - readable way. |
| 44 | +* Can directly assign values into user defined classes using annotation. |
| 45 | +* Group arguments so that it will be printed in help message in |
| 46 | + more readable way. |
33 | 47 | * Mutually exclusive argument group.
|
34 | 48 | * Read additional arguments from file.
|
| 49 | +* Argument/sub-command abbreviations. |
| 50 | + |
| 51 | +The primary documentation is done using `Sphinx |
| 52 | +<http://sphinx-doc.org/>`_. You need Sphinx to run ``mvn site``. |
0 commit comments