refine help commands/flags' help & docs

This commit is contained in:
Simon Michael 2016-05-28 22:56:47 -07:00
parent bd3212654c
commit 54237a61d6
9 changed files with 127 additions and 127 deletions

View File

@ -99,9 +99,9 @@ import Hledger.Cli.Version
helpflags :: [Flag RawOpts] helpflags :: [Flag RawOpts]
helpflags = [ helpflags = [
flagNone ["h"] (setboolopt "h") "show general usage or (after command) command usage" flagNone ["h"] (setboolopt "h") "show general usage or (after command) command usage"
,flagNone ["help"] (setboolopt "help") "show manual" ,flagNone ["help"] (setboolopt "help") "show the current program's manual as plain text (or after an add-on COMMAND, the add-on's manual)"
,flagNone ["man"] (setboolopt "man") "show manual with man" ,flagNone ["man"] (setboolopt "man") "show the current program's manual with man"
,flagNone ["info"] (setboolopt "info") "show manual with info" ,flagNone ["info"] (setboolopt "info") "show the current program's manual with info"
-- ,flagNone ["browse-args"] (setboolopt "browse-args") "use a web UI to select options and build up a command line" -- ,flagNone ["browse-args"] (setboolopt "browse-args") "use a web UI to select options and build up a command line"
,flagReq ["debug"] (\s opts -> Right $ setopt "debug" s opts) "N" "show increasing amounts of debug output if N is 1-9. With no argument, show level 1" ,flagReq ["debug"] (\s opts -> Right $ setopt "debug" s opts) "N" "show increasing amounts of debug output if N is 1-9. With no argument, show level 1"
,flagNone ["version"] (setboolopt "version") "show version information" ,flagNone ["version"] (setboolopt "version") "show version information"

View File

@ -21,7 +21,7 @@ import Hledger.Cli.CliOptions
import Hledger.Cli.DocFiles import Hledger.Cli.DocFiles
helpmode = (defCommandMode $ ["help"] ++ aliases) { helpmode = (defCommandMode $ ["help"] ++ aliases) {
modeHelp = "show manual" `withAliases` aliases modeHelp = "show any of the hledger manuals" `withAliases` aliases
,modeGroupFlags = Group { ,modeGroupFlags = Group {
groupUnnamed = [] groupUnnamed = []
,groupHidden = [] ,groupHidden = []

View File

@ -21,7 +21,7 @@ import Hledger.Cli.CliOptions
import Hledger.Cli.DocFiles import Hledger.Cli.DocFiles
infomode = (defCommandMode $ ["info"] ++ aliases) { infomode = (defCommandMode $ ["info"] ++ aliases) {
modeHelp = "show manual with info" `withAliases` aliases modeHelp = "show any of the hledger manuals with info" `withAliases` aliases
,modeGroupFlags = Group { ,modeGroupFlags = Group {
groupUnnamed = [] groupUnnamed = []
,groupHidden = [] ,groupHidden = []

View File

@ -21,7 +21,7 @@ import Hledger.Cli.CliOptions
import Hledger.Cli.DocFiles import Hledger.Cli.DocFiles
manmode = (defCommandMode $ ["man"] ++ aliases) { manmode = (defCommandMode $ ["man"] ++ aliases) {
modeHelp = "show manual with man" `withAliases` aliases modeHelp = "show any of the hledger manuals with man" `withAliases` aliases
,modeGroupFlags = Group { ,modeGroupFlags = Group {
groupUnnamed = [] groupUnnamed = []
,groupHidden = [] ,groupHidden = []

View File

@ -234,7 +234,7 @@ Total:
``` ```
## help ## help
Show one of the hledger manuals. Show any of the hledger manuals.
The `help` command displays any of the main [hledger man pages](/docs.html). The `help` command displays any of the main [hledger man pages](/docs.html).
(Unlike `hledger --help`, which displays only the hledger man page.) (Unlike `hledger --help`, which displays only the hledger man page.)
@ -304,7 +304,7 @@ Total:
``` ```
## info ## info
Show one of the hledger manuals using info. Show any of the hledger manuals using info.
The `info` command displays any of the [hledger reference manuals](/docs.html) The `info` command displays any of the [hledger reference manuals](/docs.html)
using the [info](https://en.wikipedia.org/wiki/Info_(Unix)) hypertextual documentation viewer. using the [info](https://en.wikipedia.org/wiki/Info_(Unix)) hypertextual documentation viewer.
@ -314,7 +314,7 @@ It requires the "info" program to be available in your PATH.
As with [help](#help), run it with no arguments to list available topics (manuals). As with [help](#help), run it with no arguments to list available topics (manuals).
## man ## man
Show one of the hledger manuals using man. Show any of the hledger manuals using man.
The `man` command displays any of the [hledger reference manuals](/docs.html) The `man` command displays any of the [hledger reference manuals](/docs.html)
using [man](https://en.wikipedia.org/wiki/Man_page), the standard documentation viewer on unix systems. using [man](https://en.wikipedia.org/wiki/Man_page), the standard documentation viewer on unix systems.

View File

@ -198,18 +198,18 @@ show general usage (or if after COMMAND, the command\[aq]s usage)
.RE .RE
.TP .TP
.B \f[C]\-\-help\f[] .B \f[C]\-\-help\f[]
show hledger manual (or if after an add\-on COMMAND, show the show the current program\[aq]s manual as plain text (or after an add\-on
add\-on\[aq]s manual) COMMAND, the add\-on\[aq]s manual)
.RS .RS
.RE .RE
.TP .TP
.B \f[C]\-\-man\f[] .B \f[C]\-\-man\f[]
show manual with man show the current program\[aq]s manual with man
.RS .RS
.RE .RE
.TP .TP
.B \f[C]\-\-info\f[] .B \f[C]\-\-info\f[]
show manual with info show the current program\[aq]s manual with info
.RS .RS
.RE .RE
.TP .TP
@ -1401,7 +1401,7 @@ Total:
.fi .fi
.SS help .SS help
.PP .PP
Show one of the hledger manuals. Show any of the hledger manuals.
.PP .PP
The \f[C]help\f[] command displays any of the main hledger man pages. The \f[C]help\f[] command displays any of the main hledger man pages.
(Unlike \f[C]hledger\ \-\-help\f[], which displays only the hledger man (Unlike \f[C]hledger\ \-\-help\f[], which displays only the hledger man
@ -1483,7 +1483,7 @@ Total:
.fi .fi
.SS info .SS info
.PP .PP
Show one of the hledger manuals using info. Show any of the hledger manuals using info.
.PP .PP
The \f[C]info\f[] command displays any of the hledger reference manuals The \f[C]info\f[] command displays any of the hledger reference manuals
using the info hypertextual documentation viewer. using the info hypertextual documentation viewer.
@ -1494,7 +1494,7 @@ As with help, run it with no arguments to list available topics
(manuals). (manuals).
.SS man .SS man
.PP .PP
Show one of the hledger manuals using man. Show any of the hledger manuals using man.
.PP .PP
The \f[C]man\f[] command displays any of the hledger reference manuals The \f[C]man\f[] command displays any of the hledger reference manuals
using man, the standard documentation viewer on unix systems. using man, the standard documentation viewer on unix systems.

View File

@ -162,14 +162,14 @@ available and can appear anywhere in the command line:
show general usage (or if after COMMAND, the command's usage) show general usage (or if after COMMAND, the command's usage)
`--help' `--help'
show hledger manual (or if after an add-on COMMAND, show the show the current program's manual as plain text (or after an add-on
add-on's manual) COMMAND, the add-on's manual)
`--man' `--man'
show manual with man show the current program's manual with man
`--info' `--info'
show manual with info show the current program's manual with info
`--version' `--version'
show version show version
@ -1177,7 +1177,7 @@ File: hledger.1.info, Node: help, Next: incomestatement, Prev: cashflow, Up:
4.7 help 4.7 help
======== ========
Show one of the hledger manuals. Show any of the hledger manuals.
The `help' command displays any of the main hledger man pages. The `help' command displays any of the main hledger man pages.
(Unlike `hledger --help', which displays only the hledger man page.) (Unlike `hledger --help', which displays only the hledger man page.)
@ -1252,7 +1252,7 @@ File: hledger.1.info, Node: info, Next: man, Prev: incomestatement, Up: COMM
4.9 info 4.9 info
======== ========
Show one of the hledger manuals using info. Show any of the hledger manuals using info.
The `info' command displays any of the hledger reference manuals The `info' command displays any of the hledger reference manuals
using the info hypertextual documentation viewer. This can be a very using the info hypertextual documentation viewer. This can be a very
@ -1268,7 +1268,7 @@ File: hledger.1.info, Node: man, Next: print, Prev: info, Up: COMMANDS
4.10 man 4.10 man
======== ========
Show one of the hledger manuals using man. Show any of the hledger manuals using man.
The `man' command displays any of the hledger reference manuals The `man' command displays any of the hledger reference manuals
using man, the standard documentation viewer on unix systems. This will using man, the standard documentation viewer on unix systems. This will
@ -2039,99 +2039,99 @@ in hledger add.
 
Tag Table: Tag Table:
Node: Top82 Node: Top82
Node: EXAMPLES1754 Node: EXAMPLES1748
Ref: #examples1856 Ref: #examples1850
Node: OPTIONS3860 Node: OPTIONS3854
Ref: #options3964 Ref: #options3958
Node: Multiple files7217 Node: Multiple files7275
Ref: #multiple-files7342 Ref: #multiple-files7400
Node: Repeated options7607 Node: Repeated options7665
Ref: #repeated-options7759 Ref: #repeated-options7817
Node: Depth limiting7879 Node: Depth limiting7937
Ref: #depth-limiting8024 Ref: #depth-limiting8082
Node: Smart dates8225 Node: Smart dates8283
Ref: #smart-dates8366 Ref: #smart-dates8424
Node: Reporting interval9363 Node: Reporting interval9421
Ref: #reporting-interval9522 Ref: #reporting-interval9580
Node: Period expressions9865 Node: Period expressions9923
Ref: #period-expressions10032 Ref: #period-expressions10090
Node: Regular Expressions12078 Node: Regular Expressions12136
Ref: #regular-expressions12220 Ref: #regular-expressions12278
Node: QUERIES13703 Node: QUERIES13761
Ref: #queries13807 Ref: #queries13865
Node: COMMANDS17109 Node: COMMANDS17167
Ref: #commands17223 Ref: #commands17281
Node: accounts17896 Node: accounts17954
Ref: #accounts17996 Ref: #accounts18054
Node: activity18978 Node: activity19036
Ref: #activity19090 Ref: #activity19148
Node: add19449 Node: add19507
Ref: #add19550 Ref: #add19608
Node: balance22209 Node: balance22267
Ref: #balance22322 Ref: #balance22380
Node: Flat mode25038 Node: Flat mode25096
Ref: #flat-mode25165 Ref: #flat-mode25223
Node: Depth limited balance reports25584 Node: Depth limited balance reports25642
Ref: #depth-limited-balance-reports25787 Ref: #depth-limited-balance-reports25845
Node: Multicolumn balance reports26208 Node: Multicolumn balance reports26266
Ref: #multicolumn-balance-reports26410 Ref: #multicolumn-balance-reports26468
Node: Market value31059 Node: Market value31117
Ref: #market-value31223 Ref: #market-value31281
Node: Custom balance output31716 Node: Custom balance output31774
Ref: #custom-balance-output31889 Ref: #custom-balance-output31947
Node: Output destination33993 Node: Output destination34051
Ref: #output-destination34158 Ref: #output-destination34216
Node: CSV output34428 Node: CSV output34486
Ref: #csv-output34547 Ref: #csv-output34605
Node: balancesheet34944 Node: balancesheet35002
Ref: #balancesheet35072 Ref: #balancesheet35130
Node: cashflow35724 Node: cashflow35782
Ref: #cashflow35841 Ref: #cashflow35899
Node: help36531 Node: help36589
Ref: #help36643 Ref: #help36701
Node: incomestatement37480 Node: incomestatement37538
Ref: #incomestatement37610 Ref: #incomestatement37668
Node: info38337 Node: info38395
Ref: #info38444 Ref: #info38502
Node: man38806 Node: man38864
Ref: #man38903 Ref: #man38961
Node: print39306 Node: print39364
Ref: #print39411 Ref: #print39469
Node: register40762 Node: register40820
Ref: #register40875 Ref: #register40933
Node: Custom register output45216 Node: Custom register output45274
Ref: #custom-register-output45347 Ref: #custom-register-output45405
Node: stats46644 Node: stats46702
Ref: #stats46750 Ref: #stats46808
Node: test47631 Node: test47689
Ref: #test47718 Ref: #test47776
Node: ADD-ON COMMANDS48085 Node: ADD-ON COMMANDS48143
Ref: #add-on-commands48221 Ref: #add-on-commands48279
Node: api49509 Node: api49567
Ref: #api49601 Ref: #api49659
Node: autosync49635 Node: autosync49693
Ref: #autosync49750 Ref: #autosync49808
Node: diff52065 Node: diff52123
Ref: #diff52175 Ref: #diff52233
Node: equity52839 Node: equity52897
Ref: #equity52953 Ref: #equity53011
Node: interest54281 Node: interest54339
Ref: #interest54398 Ref: #interest54456
Node: irr57482 Node: irr57540
Ref: #irr57595 Ref: #irr57653
Node: print-unique59970 Node: print-unique60028
Ref: #print-unique60100 Ref: #print-unique60158
Node: rewrite60358 Node: rewrite60416
Ref: #rewrite60477 Ref: #rewrite60535
Node: ui61006 Node: ui61064
Ref: #ui61106 Ref: #ui61164
Node: web61147 Node: web61205
Ref: #web61235 Ref: #web61293
Node: TROUBLESHOOTING61268 Node: TROUBLESHOOTING61326
Ref: #troubleshooting61387 Ref: #troubleshooting61445
Node: Run-time problems61441 Node: Run-time problems61499
Ref: #run-time-problems61584 Ref: #run-time-problems61642
Node: Known limitations63528 Node: Known limitations63586
Ref: #known-limitations63671 Ref: #known-limitations63729
 
End Tag Table End Tag Table

View File

@ -139,12 +139,12 @@ OOPPTTIIOONNSS
--hh show general usage (or if after COMMAND, the command's usage) --hh show general usage (or if after COMMAND, the command's usage)
----hheellpp show hledger manual (or if after an add-on COMMAND, show the ----hheellpp show the current program's manual as plain text (or after an
add-on's manual) add-on COMMAND, the add-on's manual)
----mmaann show manual with man ----mmaann show the current program's manual with man
----iinnffoo show manual with info ----iinnffoo show the manual with info
----vveerrssiioonn ----vveerrssiioonn
show version show version
@ -966,7 +966,7 @@ CCOOMMMMAANNDDSS
$-1 $-1
hheellpp hheellpp
Show one of the hledger manuals. Show any of the hledger manuals.
The help command displays any of the main hledger man pages. (Unlike The help command displays any of the main hledger man pages. (Unlike
hledger --help, which displays only the hledger man page.) Run it with hledger --help, which displays only the hledger man page.) Run it with
@ -1027,7 +1027,7 @@ CCOOMMMMAANNDDSS
0 0
iinnffoo iinnffoo
Show one of the hledger manuals using info. Show any of the hledger manuals using info.
The info command displays any of the hledger reference manuals using The info command displays any of the hledger reference manuals using
the info hypertextual documentation viewer. This can be a very effi- the info hypertextual documentation viewer. This can be a very effi-
@ -1038,7 +1038,7 @@ CCOOMMMMAANNDDSS
als). als).
mmaann mmaann
Show one of the hledger manuals using man. Show any of the hledger manuals using man.
The man command displays any of the hledger reference manuals using The man command displays any of the hledger reference manuals using
man, the standard documentation viewer on unix systems. This will fit man, the standard documentation viewer on unix systems. This will fit

View File

@ -26,13 +26,13 @@ General options are always available and can appear anywhere in the command line
: show general usage (or if after COMMAND, the command's usage) : show general usage (or if after COMMAND, the command's usage)
`--help` `--help`
: show hledger manual (or if after an add-on COMMAND, show the add-on's manual) : show the current program's manual as plain text (or after an add-on COMMAND, the add-on's manual)
`--man` `--man`
: show manual with man : show the current program's manual with man
`--info` `--info`
: show manual with info : show the current program's manual with info
`--version` `--version`
: show version : show version