|
| 1 | +--- |
| 2 | +synopsis: Command option help \# herald |
| 3 | +packages: [Cabal] |
| 4 | +prs: 12221 |
| 5 | +issues: 1220 |
| 6 | +--- |
| 7 | + |
| 8 | +When laying out the table of options, `Distribution.GetOpt.usageInfo` marks the |
| 9 | +first line of each help description with a preceding `#` to herald the |
| 10 | +description. Longer descriptions wrap and this herald helps to itemize or |
| 11 | +separate descriptions, like bullet points in a list. |
| 12 | + |
| 13 | +The options may overflow the columns reserved for them. If they do the |
| 14 | +description of that option starts at its normal column but on the next line |
| 15 | +down. This leads to these combinations; |
| 16 | + |
| 17 | +- short option, short description, |
| 18 | + |
| 19 | + ```pre |
| 20 | + -h, --help # Show this help text. |
| 21 | + ``` |
| 22 | +
|
| 23 | +- short option, long description, |
| 24 | +
|
| 25 | + ```pre |
| 26 | + --enable-tests # Enable dependency checking and compilation for |
| 27 | + test suites listed in the package description |
| 28 | + file. |
| 29 | + ``` |
| 30 | +
|
| 31 | +- long option, short description, |
| 32 | +
|
| 33 | + ```pre |
| 34 | + -w PATH or -wPATH, --with-compiler=PATH |
| 35 | + # Give the path to a particular compiler. |
| 36 | + ``` |
| 37 | +
|
| 38 | +- long option, long description. |
| 39 | +
|
| 40 | + ```pre |
| 41 | + -f FLAGS or -fFLAGS, --flags=FLAGS |
| 42 | + # Force values for the given flags in Cabal |
| 43 | + conditionals in the .cabal file. E.g., |
| 44 | + --flags="debug -usebytestrings" forces the |
| 45 | + flag "debug" to true and "usebytestrings" to |
| 46 | + false. |
| 47 | + ``` |
0 commit comments