doc: more deduplication of options help

Help for reporting options is now also defined once in lib.m4
(in addition to CliOptions.hs). Also fixed some duplication of general
options in docs. hledger-* manuals now include the full list of general
and reporting options; we assume that any inapplicable options get
harmlessly ignored and that this will not surprise users.
This commit is contained in:
Simon Michael 2016-06-03 09:38:06 -07:00
parent 16bb17fbe8
commit f21e9d1c25
14 changed files with 291 additions and 342 deletions

View File

@ -86,3 +86,59 @@ m4_define({{_generaloptions_}}, {{
: ignore any failing balance assertions in the journal : ignore any failing balance assertions in the journal
}} )m4_dnl }} )m4_dnl
m4_dnl
m4_define({{_reportingoptions_}}, {{
`-b --begin=DATE `
: include postings/txns on or after this date
`-e --end=DATE `
: include postings/txns before this date
`-D --daily `
: multiperiod/multicolumn report by day
`-W --weekly `
: multiperiod/multicolumn report by week
`-M --monthly `
: multiperiod/multicolumn report by month
`-Q --quarterly `
: multiperiod/multicolumn report by quarter
`-Y --yearly `
: multiperiod/multicolumn report by year
`-p --period=PERIODEXP `
: set start date, end date, and/or reporting interval all at once (overrides the flags above)
`--date2`
: show, and match with -b/-e/-p/date:, secondary dates instead
`-C --cleared `
: include only cleared postings/txns
`--pending`
: include only pending postings/txns
`-U --uncleared `
: include only uncleared (and pending) postings/txns
`-R --real `
: include only non-virtual postings
`--depth=N`
: hide accounts/postings deeper than N
`-E --empty `
: show items with zero amount, normally hidden
`-B --cost `
: show amounts in their cost price's commodity
`--pivot TAG
: will transform the journal before any other processing by replacing the account name of every posting having the tag TAG with content VALUE by the account name "TAG:VALUE".
: The TAG will only match if it is a full-length match. The pivot will only happen if the TAG is on a posting, not if it is on the transaction. If the tag value is a multi:level:account:name the new account name will be "TAG:multi:level:account:name".
}} )m4_dnl

View File

@ -47,12 +47,6 @@ server the API docs will be printed in Swagger 2.0 format.
Note: if invoking hledger\-api as a hledger subcommand, write Note: if invoking hledger\-api as a hledger subcommand, write
\f[C]\-\-\f[] before options as shown above. \f[C]\-\-\f[] before options as shown above.
.TP .TP
.B \f[C]\-f\ \-\-file\ FILE\f[]
use a different input file (default: \f[C]$LEDGER_FILE\f[] or
\f[C]~/.hledger.journal\f[])
.RS
.RE
.TP
.B \f[C]\-d\ \-\-static\-dir=DIR\f[] .B \f[C]\-d\ \-\-static\-dir=DIR\f[]
serve files from a different directory (default: \f[C]\&.\f[]) serve files from a different directory (default: \f[C]\&.\f[])
.RS .RS
@ -67,6 +61,8 @@ use a different TCP port (default: 8001)
print API docs in Swagger 2.0 format, and exit print API docs in Swagger 2.0 format, and exit
.RS .RS
.RE .RE
.PP
hledger general options:
.TP .TP
.B \f[C]\-h\f[] .B \f[C]\-h\f[]
show general usage (or after COMMAND, the command\[aq]s usage) show general usage (or after COMMAND, the command\[aq]s usage)

View File

@ -36,10 +36,6 @@ File: hledger-api.1.info, Node: OPTIONS, Prev: Top, Up: Top
Note: if invoking hledger-api as a hledger subcommand, write `--' Note: if invoking hledger-api as a hledger subcommand, write `--'
before options as shown above. before options as shown above.
`-f --file FILE'
use a different input file (default: `$LEDGER_FILE' or
`~/.hledger.journal')
`-d --static-dir=DIR' `-d --static-dir=DIR'
serve files from a different directory (default: `.') serve files from a different directory (default: `.')
@ -49,6 +45,8 @@ before options as shown above.
`--swagger' `--swagger'
print API docs in Swagger 2.0 format, and exit print API docs in Swagger 2.0 format, and exit
hledger general options:
`-h' `-h'
show general usage (or after COMMAND, the command's usage) show general usage (or after COMMAND, the command's usage)

View File

@ -50,9 +50,6 @@ the API docs will be printed in Swagger 2.0 format.
Note: if invoking hledger-api as a hledger subcommand, write `--` before options as shown above. Note: if invoking hledger-api as a hledger subcommand, write `--` before options as shown above.
`-f --file FILE`
: use a different input file (default: `$LEDGER_FILE` or `~/.hledger.journal`)
`-d --static-dir=DIR` `-d --static-dir=DIR`
: serve files from a different directory (default: `.`) : serve files from a different directory (default: `.`)
@ -62,6 +59,8 @@ Note: if invoking hledger-api as a hledger subcommand, write `--` before options
`--swagger` `--swagger`
: print API docs in Swagger 2.0 format, and exit : print API docs in Swagger 2.0 format, and exit
hledger general options:
_generaloptions_ _generaloptions_
_man_({{ _man_({{

View File

@ -37,10 +37,6 @@ OOPPTTIIOONNSS
Note: if invoking hledger-api as a hledger subcommand, write -- before Note: if invoking hledger-api as a hledger subcommand, write -- before
options as shown above. options as shown above.
--ff ----ffiillee FFIILLEE
use a different input file (default: $LEDGER_FILE or
~/.hledger.journal)
--dd ----ssttaattiicc--ddiirr==DDIIRR --dd ----ssttaattiicc--ddiirr==DDIIRR
serve files from a different directory (default: .) serve files from a different directory (default: .)
@ -50,9 +46,11 @@ OOPPTTIIOONNSS
----sswwaaggggeerr ----sswwaaggggeerr
print API docs in Swagger 2.0 format, and exit print API docs in Swagger 2.0 format, and exit
hledger general options:
--hh show general usage (or after COMMAND, the command's usage) --hh show general usage (or after COMMAND, the command's usage)
----hheellpp show the current program's manual as plain text (or after an ----hheellpp show the current program's manual as plain text (or after an
add-on COMMAND, the add-on's manual) add-on COMMAND, the add-on's manual)
----mmaann show the current program's manual with man ----mmaann show the current program's manual with man
@ -69,7 +67,7 @@ OOPPTTIIOONNSS
use a different input file. For stdin, use - use a different input file. For stdin, use -
----rruulleess--ffiillee==RRUULLEESSFFIILLEE ----rruulleess--ffiillee==RRUULLEESSFFIILLEE
Conversion rules file to use when reading CSV (default: Conversion rules file to use when reading CSV (default:
FILE.rules) FILE.rules)
----aalliiaass==OOLLDD==NNEEWW ----aalliiaass==OOLLDD==NNEEWW
@ -79,7 +77,7 @@ OOPPTTIIOONNSS
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
EENNVVIIRROONNMMEENNTT EENNVVIIRROONNMMEENNTT
LLEEDDGGEERR__FFIILLEE sets the default journal file path. If not set, it is LLEEDDGGEERR__FFIILLEE sets the default journal file path. If not set, it is
~/.hledger.journal. ~/.hledger.journal.
FFIILLEESS FFIILLEESS
@ -88,13 +86,13 @@ FFIILLEESS
file. file.
BBUUGGSS BBUUGGSS
The need to precede options with -- when invoked from hledger is awk- The need to precede options with -- when invoked from hledger is awk-
ward. ward.
RREEPPOORRTTIINNGG BBUUGGSS RREEPPOORRTTIINNGG BBUUGGSS
Report bugs at http://bugs.hledger.org (or on the #hledger IRC channel Report bugs at http://bugs.hledger.org (or on the #hledger IRC channel
or hledger mail list) or hledger mail list)
@ -108,7 +106,7 @@ CCOOPPYYRRIIGGHHTT
SSEEEE AALLSSOO SSEEEE AALLSSOO
hledger(1), hledger-ui(1), hledger-web(1), hledger-api(1), hledger(1), hledger-ui(1), hledger-web(1), hledger-api(1),
hledger_csv(5), hledger_journal(5), hledger_timeclock(5), hledger_time- hledger_csv(5), hledger_journal(5), hledger_timeclock(5), hledger_time-
dot(5), ledger(1) dot(5), ledger(1)

View File

@ -68,6 +68,8 @@ show amounts as their current market value in their default valuation
commodity (accounts screen only) commodity (accounts screen only)
.RS .RS
.RE .RE
.PP
hledger general options:
.TP .TP
.B \f[C]\-h\f[] .B \f[C]\-h\f[]
show general usage (or after COMMAND, the command\[aq]s usage) show general usage (or after COMMAND, the command\[aq]s usage)
@ -120,35 +122,8 @@ display accounts named OLD as NEW
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
.RS .RS
.RE .RE
.SS hledger options
.PP .PP
The following common hledger options should also work: hledger reporting options:
.TP
.B \f[C]\-f\ FILE\ \-\-file=FILE\f[]
use a different input file.
For stdin, use \-
.RS
.RE
.TP
.B \f[C]\-\-rules\-file=RULESFILE\f[]
Conversion rules file to use when reading CSV (default: FILE.rules)
.RS
.RE
.TP
.B \f[C]\-\-alias=OLD=NEW\f[]
display accounts named OLD as NEW
.RS
.RE
.TP
.B \f[C]\-\-ignore\-assertions\f[]
ignore any failing balance assertions in the journal
.RS
.RE
.TP
.B \f[C]\-\-debug=N\f[]
show debug output if N is 1\-9 (default: 0)
.RS
.RE
.TP .TP
.B \f[C]\-b\ \-\-begin=DATE\f[] .B \f[C]\-b\ \-\-begin=DATE\f[]
include postings/txns on or after this date include postings/txns on or after this date
@ -160,6 +135,31 @@ include postings/txns before this date
.RS .RS
.RE .RE
.TP .TP
.B \f[C]\-D\ \-\-daily\f[]
multiperiod/multicolumn report by day
.RS
.RE
.TP
.B \f[C]\-W\ \-\-weekly\f[]
multiperiod/multicolumn report by week
.RS
.RE
.TP
.B \f[C]\-M\ \-\-monthly\f[]
multiperiod/multicolumn report by month
.RS
.RE
.TP
.B \f[C]\-Q\ \-\-quarterly\f[]
multiperiod/multicolumn report by quarter
.RS
.RE
.TP
.B \f[C]\-Y\ \-\-yearly\f[]
multiperiod/multicolumn report by year
.RS
.RE
.TP
.B \f[C]\-p\ \-\-period=PERIODEXP\f[] .B \f[C]\-p\ \-\-period=PERIODEXP\f[]
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
@ -197,7 +197,7 @@ hide accounts/postings deeper than N
.RE .RE
.TP .TP
.B \f[C]\-E\ \-\-empty\f[] .B \f[C]\-E\ \-\-empty\f[]
show empty/zero things which are normally omitted show items with zero amount, normally hidden
.RS .RS
.RE .RE
.TP .TP
@ -205,6 +205,20 @@ show empty/zero things which are normally omitted
show amounts in their cost price\[aq]s commodity show amounts in their cost price\[aq]s commodity
.RS .RS
.RE .RE
.TP
.B `\-\-pivot TAG
will transform the journal before any other processing by replacing the
account name of every posting having the tag TAG with content VALUE by
the account name "TAG:VALUE".
.RS
.RE
The TAG will only match if it is a full\-length match.
The pivot will only happen if the TAG is on a posting, not if it is on
the transaction.
If the tag value is a multi:level:account:name the new account name will
be "TAG:multi:level:account:name".
.RS
.RE
.SH KEYS .SH KEYS
.PP .PP
Generally the cursor keys navigate; \f[C]right\f[] (or \f[C]enter\f[]) Generally the cursor keys navigate; \f[C]right\f[] (or \f[C]enter\f[])

View File

@ -54,6 +54,8 @@ the data.
show amounts as their current market value in their default show amounts as their current market value in their default
valuation commodity (accounts screen only) valuation commodity (accounts screen only)
hledger general options:
`-h' `-h'
show general usage (or after COMMAND, the command's usage) show general usage (or after COMMAND, the command's usage)
@ -85,32 +87,7 @@ the data.
`--ignore-assertions' `--ignore-assertions'
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
* Menu: hledger reporting options:
* hledger options::

File: hledger-ui.1.info, Node: hledger options, Up: OPTIONS
1.1 hledger options
===================
The following common hledger options should also work:
`-f FILE --file=FILE'
use a different input file. For stdin, use -
`--rules-file=RULESFILE'
Conversion rules file to use when reading CSV (default: FILE.rules)
`--alias=OLD=NEW'
display accounts named OLD as NEW
`--ignore-assertions'
ignore any failing balance assertions in the journal
`--debug=N'
show debug output if N is 1-9 (default: 0)
`-b --begin=DATE' `-b --begin=DATE'
include postings/txns on or after this date include postings/txns on or after this date
@ -118,6 +95,21 @@ The following common hledger options should also work:
`-e --end=DATE' `-e --end=DATE'
include postings/txns before this date include postings/txns before this date
`-D --daily'
multiperiod/multicolumn report by day
`-W --weekly'
multiperiod/multicolumn report by week
`-M --monthly'
multiperiod/multicolumn report by month
`-Q --quarterly'
multiperiod/multicolumn report by quarter
`-Y --yearly'
multiperiod/multicolumn report by year
`-p --period=PERIODEXP' `-p --period=PERIODEXP'
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
@ -141,11 +133,20 @@ The following common hledger options should also work:
hide accounts/postings deeper than N hide accounts/postings deeper than N
`-E --empty' `-E --empty'
show empty/zero things which are normally omitted show items with zero amount, normally hidden
`-B --cost' `-B --cost'
show amounts in their cost price's commodity show amounts in their cost price's commodity
`-pivot TAG
will transform the journal before any other processing by
replacing the account name of every posting having the tag TAG
with content VALUE by the account name "TAG:VALUE". The TAG will
only match if it is a full-length match. The pivot will only
happen if the TAG is on a posting, not if it is on the transaction.
If the tag value is a multi:level:account:name the new account
name will be "TAG:multi:level:account:name".
 
File: hledger-ui.1.info, Node: KEYS, Next: SCREENS, Prev: OPTIONS, Up: Top File: hledger-ui.1.info, Node: KEYS, Next: SCREENS, Prev: OPTIONS, Up: Top
@ -287,19 +288,17 @@ Tag Table:
Node: Top88 Node: Top88
Node: OPTIONS714 Node: OPTIONS714
Ref: #options813 Ref: #options813
Node: hledger options2134 Node: KEYS3687
Ref: #hledger-options2240 Ref: #keys3784
Node: KEYS3423 Node: SCREENS4181
Ref: #keys3520 Ref: #screens4268
Node: SCREENS3917 Node: Accounts screen4358
Ref: #screens4004 Ref: #accounts-screen4488
Node: Accounts screen4094 Node: Register screen5333
Ref: #accounts-screen4224 Ref: #register-screen5490
Node: Register screen5069 Node: Transaction screen6872
Ref: #register-screen5226 Ref: #transaction-screen7032
Node: Transaction screen6608 Node: Error screen7899
Ref: #transaction-screen6768 Ref: #error-screen8023
Node: Error screen7635
Ref: #error-screen7759
 
End Tag Table End Tag Table

View File

@ -74,59 +74,13 @@ Any QUERYARGS are interpreted as a hledger search query which filters the data.
: show amounts as their current market value in their default valuation commodity : show amounts as their current market value in their default valuation commodity
(accounts screen only) (accounts screen only)
hledger general options:
_generaloptions_ _generaloptions_
## hledger options hledger reporting options:
The following common hledger options should also work: _reportingoptions_
`-f FILE --file=FILE`
: use a different input file. For stdin, use -
`--rules-file=RULESFILE`
: Conversion rules file to use when reading CSV (default: FILE.rules)
`--alias=OLD=NEW`
: display accounts named OLD as NEW
`--ignore-assertions`
: ignore any failing balance assertions in the journal
`--debug=N`
: show debug output if N is 1-9 (default: 0)
`-b --begin=DATE`
: include postings/txns on or after this date
`-e --end=DATE`
: include postings/txns before this date
`-p --period=PERIODEXP`
: set start date, end date, and/or reporting interval all at once (overrides the flags above)
`--date2`
: show, and match with -b/-e/-p/date:, secondary dates instead
`-C --cleared`
: include only cleared postings/txns
`--pending`
: include only pending postings/txns
`-U --uncleared`
: include only uncleared (and pending) postings/txns
`-R --real`
: include only non-virtual postings
`--depth=N`
: hide accounts/postings deeper than N
`-E --empty`
: show empty/zero things which are normally omitted
`-B --cost`
: show amounts in their cost price's commodity
# KEYS # KEYS

View File

@ -54,6 +54,8 @@ OOPPTTIIOONNSS
show amounts as their current market value in their default val- show amounts as their current market value in their default val-
uation commodity (accounts screen only) uation commodity (accounts screen only)
hledger general options:
--hh show general usage (or after COMMAND, the command's usage) --hh show general usage (or after COMMAND, the command's usage)
----hheellpp show the current program's manual as plain text (or after an ----hheellpp show the current program's manual as plain text (or after an
@ -82,24 +84,7 @@ OOPPTTIIOONNSS
----iiggnnoorree--aasssseerrttiioonnss ----iiggnnoorree--aasssseerrttiioonnss
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
hhlleeddggeerr ooppttiioonnss hledger reporting options:
The following common hledger options should also work:
--ff FFIILLEE ----ffiillee==FFIILLEE
use a different input file. For stdin, use -
----rruulleess--ffiillee==RRUULLEESSFFIILLEE
Conversion rules file to use when reading CSV (default:
FILE.rules)
----aalliiaass==OOLLDD==NNEEWW
display accounts named OLD as NEW
----iiggnnoorree--aasssseerrttiioonnss
ignore any failing balance assertions in the journal
----ddeebbuugg==NN
show debug output if N is 1-9 (default: 0)
--bb ----bbeeggiinn==DDAATTEE --bb ----bbeeggiinn==DDAATTEE
include postings/txns on or after this date include postings/txns on or after this date
@ -107,8 +92,23 @@ OOPPTTIIOONNSS
--ee ----eenndd==DDAATTEE --ee ----eenndd==DDAATTEE
include postings/txns before this date include postings/txns before this date
--DD ----ddaaiillyy
multiperiod/multicolumn report by day
--WW ----wweeeekkllyy
multiperiod/multicolumn report by week
--MM ----mmoonntthhllyy
multiperiod/multicolumn report by month
--QQ ----qquuaarrtteerrllyy
multiperiod/multicolumn report by quarter
--YY ----yyeeaarrllyy
multiperiod/multicolumn report by year
--pp ----ppeerriioodd==PPEERRIIOODDEEXXPP --pp ----ppeerriioodd==PPEERRIIOODDEEXXPP
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
----ddaattee22 ----ddaattee22
@ -130,11 +130,20 @@ OOPPTTIIOONNSS
hide accounts/postings deeper than N hide accounts/postings deeper than N
--EE ----eemmppttyy --EE ----eemmppttyy
show empty/zero things which are normally omitted show items with zero amount, normally hidden
--BB ----ccoosstt --BB ----ccoosstt
show amounts in their cost price's commodity show amounts in their cost price's commodity
``----ppiivvoott TTAAGG
will transform the journal before any other processing by
replacing the account name of every posting having the tag TAG
with content VALUE by the account name "TAG:VALUE".
The TAG will only match if it is a full-length match. The pivot will
only happen if the TAG is on a posting, not if it is on the transac-
tion. If the tag value is a multi:level:account:name the new account
name will be "TAG:multi:level:account:name".
KKEEYYSS KKEEYYSS
Generally the cursor keys navigate; right (or enter) goes deeper, left Generally the cursor keys navigate; right (or enter) goes deeper, left
returns to the previous screen, up/down/page up/page down/home/end move returns to the previous screen, up/down/page up/page down/home/end move

View File

@ -113,6 +113,8 @@ serve them from another server for efficiency, you would set the url
with this. with this.
.RS .RS
.RE .RE
.PP
hledger general options:
.TP .TP
.B \f[C]\-h\f[] .B \f[C]\-h\f[]
show general usage (or after COMMAND, the command\[aq]s usage) show general usage (or after COMMAND, the command\[aq]s usage)
@ -165,35 +167,8 @@ display accounts named OLD as NEW
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
.RS .RS
.RE .RE
.SS hledger options
.PP .PP
The following common hledger options should also work: hledger reporting options:
.TP
.B \f[C]\-f\ FILE\ \-\-file=FILE\f[]
use a different input file.
For stdin, use \-
.RS
.RE
.TP
.B \f[C]\-\-rules\-file=RULESFILE\f[]
Conversion rules file to use when reading CSV (default: FILE.rules)
.RS
.RE
.TP
.B \f[C]\-\-alias=OLD=NEW\f[]
display accounts named OLD as NEW
.RS
.RE
.TP
.B \f[C]\-\-ignore\-assertions\f[]
ignore any failing balance assertions in the journal
.RS
.RE
.TP
.B \f[C]\-\-debug=N\f[]
show debug output if N is 1\-9 (default: 0)
.RS
.RE
.TP .TP
.B \f[C]\-b\ \-\-begin=DATE\f[] .B \f[C]\-b\ \-\-begin=DATE\f[]
include postings/txns on or after this date include postings/txns on or after this date
@ -205,6 +180,31 @@ include postings/txns before this date
.RS .RS
.RE .RE
.TP .TP
.B \f[C]\-D\ \-\-daily\f[]
multiperiod/multicolumn report by day
.RS
.RE
.TP
.B \f[C]\-W\ \-\-weekly\f[]
multiperiod/multicolumn report by week
.RS
.RE
.TP
.B \f[C]\-M\ \-\-monthly\f[]
multiperiod/multicolumn report by month
.RS
.RE
.TP
.B \f[C]\-Q\ \-\-quarterly\f[]
multiperiod/multicolumn report by quarter
.RS
.RE
.TP
.B \f[C]\-Y\ \-\-yearly\f[]
multiperiod/multicolumn report by year
.RS
.RE
.TP
.B \f[C]\-p\ \-\-period=PERIODEXP\f[] .B \f[C]\-p\ \-\-period=PERIODEXP\f[]
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
@ -242,7 +242,7 @@ hide accounts/postings deeper than N
.RE .RE
.TP .TP
.B \f[C]\-E\ \-\-empty\f[] .B \f[C]\-E\ \-\-empty\f[]
show empty/zero things which are normally omitted show items with zero amount, normally hidden
.RS .RS
.RE .RE
.TP .TP
@ -250,6 +250,20 @@ show empty/zero things which are normally omitted
show amounts in their cost price\[aq]s commodity show amounts in their cost price\[aq]s commodity
.RS .RS
.RE .RE
.TP
.B `\-\-pivot TAG
will transform the journal before any other processing by replacing the
account name of every posting having the tag TAG with content VALUE by
the account name "TAG:VALUE".
.RS
.RE
The TAG will only match if it is a full\-length match.
The pivot will only happen if the TAG is on a posting, not if it is on
the transaction.
If the tag value is a multi:level:account:name the new account name will
be "TAG:multi:level:account:name".
.RS
.RE
.SH ENVIRONMENT .SH ENVIRONMENT
.PP .PP
\f[B]LEDGER_FILE\f[] sets the default journal file path. \f[B]LEDGER_FILE\f[] sets the default journal file path.

View File

@ -91,6 +91,8 @@ before options as shown above.
them from another server for efficiency, you would set the url them from another server for efficiency, you would set the url
with this. with this.
hledger general options:
`-h' `-h'
show general usage (or after COMMAND, the command's usage) show general usage (or after COMMAND, the command's usage)
@ -122,32 +124,7 @@ before options as shown above.
`--ignore-assertions' `--ignore-assertions'
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
* Menu: hledger reporting options:
* hledger options::

File: hledger-web.1.info, Node: hledger options, Up: OPTIONS
1.1 hledger options
===================
The following common hledger options should also work:
`-f FILE --file=FILE'
use a different input file. For stdin, use -
`--rules-file=RULESFILE'
Conversion rules file to use when reading CSV (default: FILE.rules)
`--alias=OLD=NEW'
display accounts named OLD as NEW
`--ignore-assertions'
ignore any failing balance assertions in the journal
`--debug=N'
show debug output if N is 1-9 (default: 0)
`-b --begin=DATE' `-b --begin=DATE'
include postings/txns on or after this date include postings/txns on or after this date
@ -155,6 +132,21 @@ The following common hledger options should also work:
`-e --end=DATE' `-e --end=DATE'
include postings/txns before this date include postings/txns before this date
`-D --daily'
multiperiod/multicolumn report by day
`-W --weekly'
multiperiod/multicolumn report by week
`-M --monthly'
multiperiod/multicolumn report by month
`-Q --quarterly'
multiperiod/multicolumn report by quarter
`-Y --yearly'
multiperiod/multicolumn report by year
`-p --period=PERIODEXP' `-p --period=PERIODEXP'
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
@ -178,18 +170,25 @@ The following common hledger options should also work:
hide accounts/postings deeper than N hide accounts/postings deeper than N
`-E --empty' `-E --empty'
show empty/zero things which are normally omitted show items with zero amount, normally hidden
`-B --cost' `-B --cost'
show amounts in their cost price's commodity show amounts in their cost price's commodity
`-pivot TAG
will transform the journal before any other processing by
replacing the account name of every posting having the tag TAG
with content VALUE by the account name "TAG:VALUE". The TAG will
only match if it is a full-length match. The pivot will only
happen if the TAG is on a posting, not if it is on the transaction.
If the tag value is a multi:level:account:name the new account
name will be "TAG:multi:level:account:name".
 
Tag Table: Tag Table:
Node: Top90 Node: Top90
Node: OPTIONS2868 Node: OPTIONS2868
Ref: #options2955 Ref: #options2955
Node: hledger options4373
Ref: #hledger-options4480
 
End Tag Table End Tag Table

View File

@ -121,59 +121,13 @@ You would change this when sharing over the network, or integrating within a lar
hledger-web normally serves static files itself, but if you wanted to hledger-web normally serves static files itself, but if you wanted to
serve them from another server for efficiency, you would set the url with this. serve them from another server for efficiency, you would set the url with this.
hledger general options:
_generaloptions_ _generaloptions_
## hledger options hledger reporting options:
The following common hledger options should also work: _reportingoptions_
`-f FILE --file=FILE`
: use a different input file. For stdin, use -
`--rules-file=RULESFILE`
: Conversion rules file to use when reading CSV (default: FILE.rules)
`--alias=OLD=NEW`
: display accounts named OLD as NEW
`--ignore-assertions`
: ignore any failing balance assertions in the journal
`--debug=N`
: show debug output if N is 1-9 (default: 0)
`-b --begin=DATE`
: include postings/txns on or after this date
`-e --end=DATE`
: include postings/txns before this date
`-p --period=PERIODEXP`
: set start date, end date, and/or reporting interval all at once (overrides the flags above)
`--date2`
: show, and match with -b/-e/-p/date:, secondary dates instead
`-C --cleared`
: include only cleared postings/txns
`--pending`
: include only pending postings/txns
`-U --uncleared`
: include only uncleared (and pending) postings/txns
`-R --real`
: include only non-virtual postings
`--depth=N`
: hide accounts/postings deeper than N
`-E --empty`
: show empty/zero things which are normally omitted
`-B --cost`
: show amounts in their cost price's commodity
_man_({{ _man_({{

View File

@ -92,6 +92,8 @@ OOPPTTIIOONNSS
them from another server for efficiency, you would set the url them from another server for efficiency, you would set the url
with this. with this.
hledger general options:
--hh show general usage (or after COMMAND, the command's usage) --hh show general usage (or after COMMAND, the command's usage)
----hheellpp show the current program's manual as plain text (or after an ----hheellpp show the current program's manual as plain text (or after an
@ -120,24 +122,7 @@ OOPPTTIIOONNSS
----iiggnnoorree--aasssseerrttiioonnss ----iiggnnoorree--aasssseerrttiioonnss
ignore any failing balance assertions in the journal ignore any failing balance assertions in the journal
hhlleeddggeerr ooppttiioonnss hledger reporting options:
The following common hledger options should also work:
--ff FFIILLEE ----ffiillee==FFIILLEE
use a different input file. For stdin, use -
----rruulleess--ffiillee==RRUULLEESSFFIILLEE
Conversion rules file to use when reading CSV (default:
FILE.rules)
----aalliiaass==OOLLDD==NNEEWW
display accounts named OLD as NEW
----iiggnnoorree--aasssseerrttiioonnss
ignore any failing balance assertions in the journal
----ddeebbuugg==NN
show debug output if N is 1-9 (default: 0)
--bb ----bbeeggiinn==DDAATTEE --bb ----bbeeggiinn==DDAATTEE
include postings/txns on or after this date include postings/txns on or after this date
@ -145,8 +130,23 @@ OOPPTTIIOONNSS
--ee ----eenndd==DDAATTEE --ee ----eenndd==DDAATTEE
include postings/txns before this date include postings/txns before this date
--DD ----ddaaiillyy
multiperiod/multicolumn report by day
--WW ----wweeeekkllyy
multiperiod/multicolumn report by week
--MM ----mmoonntthhllyy
multiperiod/multicolumn report by month
--QQ ----qquuaarrtteerrllyy
multiperiod/multicolumn report by quarter
--YY ----yyeeaarrllyy
multiperiod/multicolumn report by year
--pp ----ppeerriioodd==PPEERRIIOODDEEXXPP --pp ----ppeerriioodd==PPEERRIIOODDEEXXPP
set start date, end date, and/or reporting interval all at once set start date, end date, and/or reporting interval all at once
(overrides the flags above) (overrides the flags above)
----ddaattee22 ----ddaattee22
@ -168,11 +168,20 @@ OOPPTTIIOONNSS
hide accounts/postings deeper than N hide accounts/postings deeper than N
--EE ----eemmppttyy --EE ----eemmppttyy
show empty/zero things which are normally omitted show items with zero amount, normally hidden
--BB ----ccoosstt --BB ----ccoosstt
show amounts in their cost price's commodity show amounts in their cost price's commodity
``----ppiivvoott TTAAGG
will transform the journal before any other processing by
replacing the account name of every posting having the tag TAG
with content VALUE by the account name "TAG:VALUE".
The TAG will only match if it is a full-length match. The pivot will
only happen if the TAG is on a posting, not if it is on the transac-
tion. If the tag value is a multi:level:account:name the new account
name will be "TAG:multi:level:account:name".
EENNVVIIRROONNMMEENNTT EENNVVIIRROONNMMEENNTT
LLEEDDGGEERR__FFIILLEE sets the default journal file path. If not set, it is LLEEDDGGEERR__FFIILLEE sets the default journal file path. If not set, it is
~/.hledger.journal. ~/.hledger.journal.

View File

@ -28,57 +28,7 @@ Common reporting options are supported by most commands where applicable,
and individual commands may provide additional command-specific options. and individual commands may provide additional command-specific options.
Both of these must be written after the command name. Both of these must be written after the command name.
`-b --begin=DATE ` _reportingoptions_
: include postings/txns on or after this date
`-e --end=DATE `
: include postings/txns before this date
`-D --daily `
: multiperiod/multicolumn report by day
`-W --weekly `
: multiperiod/multicolumn report by week
`-M --monthly `
: multiperiod/multicolumn report by month
`-Q --quarterly `
: multiperiod/multicolumn report by quarter
`-Y --yearly `
: multiperiod/multicolumn report by year
`-p --period=PERIODEXP `
: set start date, end date, and/or reporting interval all at once (overrides the flags above)
`--date2`
: show, and match with -b/-e/-p/date:, secondary dates instead
`-C --cleared `
: include only cleared postings/txns
`--pending`
: include only pending postings/txns
`-U --uncleared `
: include only uncleared (and pending) postings/txns
`-R --real `
: include only non-virtual postings
`--depth=N`
: hide accounts/postings deeper than N
`-E --empty `
: show items with zero amount, normally hidden
`-B --cost `
: show amounts in their cost price's commodity
`--pivot TAG
: will transform the journal before any other processing by replacing the account name of every posting having the tag TAG with content VALUE by the account name "TAG:VALUE".
: The TAG will only match if it is a full-length match. The pivot will only happen if the TAG is on a posting, not if it is on the transaction. If the tag value is a multi:level:account:name the new account name will be "TAG:multi:level:account:name".
## Multiple files ## Multiple files