From 91959899790ff121f4ce3a05a953abae6e33c01e Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Fri, 7 Jul 2017 15:40:50 +0100 Subject: [PATCH] doc: update builtin manuals --- hledger-api/doc/hledger-api.1 | 17 +-- hledger-api/doc/hledger-api.1.info | 11 +- hledger-api/doc/hledger-api.1.txt | 9 +- hledger/doc/hledger.1 | 32 ++-- hledger/doc/hledger.1.info | 226 ++++++++++++++--------------- hledger/doc/hledger.1.txt | 220 ++++++++++++++-------------- 6 files changed, 240 insertions(+), 275 deletions(-) diff --git a/hledger-api/doc/hledger-api.1 b/hledger-api/doc/hledger-api.1 index d9f873086..71c3de3d2 100644 --- a/hledger-api/doc/hledger-api.1 +++ b/hledger-api/doc/hledger-api.1 @@ -79,25 +79,10 @@ show version .RS .RE .TP -.B \f[C]\-h\f[] +.B \f[C]\-h\ \-\-help\f[] show usage .RS .RE -.TP -.B \f[C]\-\-help\f[] -show manual as plain text -.RS -.RE -.TP -.B \f[C]\-\-man\f[] -show manual with man -.RS -.RE -.TP -.B \f[C]\-\-info\f[] -show manual with info -.RS -.RE .SH ENVIRONMENT .PP \f[B]LEDGER_FILE\f[] The journal file path when not specified with diff --git a/hledger-api/doc/hledger-api.1.info b/hledger-api/doc/hledger-api.1.info index 3e83c4478..5fb45baf2 100644 --- a/hledger-api/doc/hledger-api.1.info +++ b/hledger-api/doc/hledger-api.1.info @@ -57,18 +57,9 @@ options as shown above. '--version' show version -'-h' +'-h --help' show usage -'--help' - - show manual as plain text -'--man' - - show manual with man -'--info' - - show manual with info  Tag Table: diff --git a/hledger-api/doc/hledger-api.1.txt b/hledger-api/doc/hledger-api.1.txt index edd500a3d..2e4ab8d6e 100644 --- a/hledger-api/doc/hledger-api.1.txt +++ b/hledger-api/doc/hledger-api.1.txt @@ -59,13 +59,8 @@ OPTIONS --version show version - -h show usage - - --help show manual as plain text - - --man show manual with man - - --info show manual with info + -h --help + show usage ENVIRONMENT LEDGER_FILE The journal file path when not specified with -f. Default: diff --git a/hledger/doc/hledger.1 b/hledger/doc/hledger.1 index e474e6a0a..5f91aeacf 100644 --- a/hledger/doc/hledger.1 +++ b/hledger/doc/hledger.1 @@ -1848,20 +1848,23 @@ multicolumn balance reports you can alter the report mode with .PP Show any of the hledger manuals. .PP -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 -page.) Run it with no arguments to list available topics (their names -are shortened for easier typing), and run \f[C]hledger\ help\ TOPIC\f[] -to select one. -The output is similar to a man page, but fixed width. -It may be long, so you may wish to pipe it into a pager. -See also info and man. +The \f[C]help\f[] command displays any of the main hledger manuals, in +one of several ways. +Run it with no argument to list the manuals (their names are shortened +for easier typing), and run \f[C]hledger\ help\ MANUAL\f[] to select +one. +.PP +hledger help will choose one of these docs viewers, in order of +preference: info, man, $PAGER, less, stdout (and it always prints on +stdout when piped). +Or you can force a particular viewer with the \f[C]\-\-info\f[], +\f[C]\-\-man\f[], \f[C]\-\-pager\f[], \f[C]\-\-cat\f[] flags. .IP .nf \f[C] $\ hledger\ help -Choose\ a\ topic,\ eg:\ hledger\ help\ cli -cli,\ ui,\ web,\ api,\ journal,\ csv,\ timeclock,\ timedot +Please\ choose\ a\ manual: +hledger\ help\ cli|ui|web|api|journal|csv|timeclock|timedot \f[] .fi .IP @@ -1877,9 +1880,7 @@ NAME \ \ \ \ \ \ \ hledger\ \-\ a\ command\-line\ accounting\ tool SYNOPSIS -\ \ \ \ \ \ \ hledger\ [\-f\ FILE]\ COMMAND\ [OPTIONS]\ [CMDARGS] -\ \ \ \ \ \ \ hledger\ [\-f\ FILE]\ ADDONCMD\ \-\-\ [OPTIONS]\ [CMDARGS] -: +\ \ \ \ \ \ \ hledger\ [\-f\ FILE]\ COMMAND\ [OPTIONS]\ [ARGS] \f[] .fi .SS incomestatement @@ -1981,9 +1982,9 @@ report period. Normally incomestatement shows revenues/expenses per period, though as with multicolumn balance reports you can alter the report mode with \f[C]\-\-change\f[]/\f[C]\-\-cumulative\f[]/\f[C]\-\-historical\f[]. -.SS info .PP -Show any of the hledger manuals using info. +\&... +## info Show any of the hledger manuals using info. .PP The \f[C]info\f[] command displays any of the hledger reference manuals using the info hypertextual documentation viewer. @@ -2004,6 +2005,7 @@ It requires the "man" program to be available in your PATH. .PP As with help, run it with no arguments to list available topics (manuals). +``` .SS print .PP Show transactions from the journal. diff --git a/hledger/doc/hledger.1.info b/hledger/doc/hledger.1.info index 8a369b8c7..6089d9ae4 100644 --- a/hledger/doc/hledger.1.info +++ b/hledger/doc/hledger.1.info @@ -786,7 +786,6 @@ displayed in the command list ('hledger is'). * cashflow:: * help:: * incomestatement:: -* info:: * man:: * print:: * register:: @@ -1441,16 +1440,19 @@ File: hledger.1.info, Node: help, Next: incomestatement, Prev: cashflow, Up: Show any of the hledger manuals. - The 'help' command displays any of the main hledger man pages. -(Unlike 'hledger --help', which displays only the hledger man page.) -Run it with no arguments to list available topics (their names are -shortened for easier typing), and run 'hledger help TOPIC' to select -one. The output is similar to a man page, but fixed width. It may be -long, so you may wish to pipe it into a pager. See also info and man. + The 'help' command displays any of the main hledger manuals, in one +of several ways. Run it with no argument to list the manuals (their +names are shortened for easier typing), and run 'hledger help MANUAL' to +select one. + + hledger help will choose one of these docs viewers, in order of +preference: info, man, $PAGER, less, stdout (and it always prints on +stdout when piped). Or you can force a particular viewer with the +'--info', '--man', '--pager', '--cat' flags. $ hledger help -Choose a topic, eg: hledger help cli -cli, ui, web, api, journal, csv, timeclock, timedot +Please choose a manual: +hledger help cli|ui|web|api|journal|csv|timeclock|timedot $ hledger help cli | less @@ -1462,12 +1464,10 @@ NAME hledger - a command-line accounting tool SYNOPSIS - hledger [-f FILE] COMMAND [OPTIONS] [CMDARGS] - hledger [-f FILE] ADDONCMD -- [OPTIONS] [CMDARGS] -: + hledger [-f FILE] COMMAND [OPTIONS] [ARGS]  -File: hledger.1.info, Node: incomestatement, Next: info, Prev: help, Up: COMMANDS +File: hledger.1.info, Node: incomestatement, Next: man, Prev: help, Up: COMMANDS 4.8 incomestatement =================== @@ -1542,13 +1542,7 @@ each report period. Normally incomestatement shows revenues/expenses per period, though as with multicolumn balance reports you can alter the report mode with '--change'/'--cumulative'/'--historical'. - -File: hledger.1.info, Node: info, Next: man, Prev: incomestatement, Up: COMMANDS - -4.9 info -======== - -Show any of the hledger manuals using info. + ... ## info Show any of the hledger manuals using info. The 'info' command displays any of the hledger reference manuals using the info hypertextual documentation viewer. This can be a very @@ -1559,10 +1553,10 @@ to be available in your PATH. (manuals).  -File: hledger.1.info, Node: man, Next: print, Prev: info, Up: COMMANDS +File: hledger.1.info, Node: man, Next: print, Prev: incomestatement, Up: COMMANDS -4.10 man -======== +4.9 man +======= Show any of the hledger manuals using man. @@ -1573,12 +1567,12 @@ automatically. It requires the "man" program to be available in your PATH. As with help, run it with no arguments to list available topics -(manuals). +(manuals). "'  File: hledger.1.info, Node: print, Next: register, Prev: man, Up: COMMANDS -4.11 print +4.10 print ========== Show transactions from the journal. @@ -1672,7 +1666,7 @@ $ hledger print -Ocsv  File: hledger.1.info, Node: register, Next: stats, Prev: print, Up: COMMANDS -4.12 register +4.11 register ============= Show postings and their running total. Alias: reg. @@ -1777,7 +1771,7 @@ length and comparable to the others in the report.  File: hledger.1.info, Node: Custom register output, Up: register -4.12.1 Custom register output +4.11.1 Custom register output ----------------------------- register uses the full terminal width by default, except on windows. @@ -1809,7 +1803,7 @@ output.  File: hledger.1.info, Node: stats, Next: test, Prev: register, Up: COMMANDS -4.13 stats +4.12 stats ========== Show some journal statistics. @@ -1841,7 +1835,7 @@ output destination.  File: hledger.1.info, Node: test, Prev: stats, Up: COMMANDS -4.14 test +4.13 test ========= Run built-in unit tests. @@ -2139,93 +2133,91 @@ Node: QUERIES21565 Ref: #queries21669 Node: COMMANDS25334 Ref: #commands25448 -Node: accounts26121 -Ref: #accounts26221 -Node: activity27203 -Ref: #activity27315 -Node: add27674 -Ref: #add27775 -Node: balance30433 -Ref: #balance30546 -Node: Flat mode33561 -Ref: #flat-mode33688 -Node: Depth limited balance reports34108 -Ref: #depth-limited-balance-reports34311 -Node: Multicolumn balance reports34731 -Ref: #multicolumn-balance-reports34942 -Node: Custom balance output39590 -Ref: #custom-balance-output39774 -Node: Colour support41867 -Ref: #colour-support42028 -Node: Output destination42201 -Ref: #output-destination42359 -Node: CSV output42629 -Ref: #csv-output42748 -Node: balancesheet43145 -Ref: #balancesheet43273 -Node: cashflow45180 -Ref: #cashflow45297 -Node: help47165 -Ref: #help47277 -Node: incomestatement48115 -Ref: #incomestatement48245 -Node: info50137 -Ref: #info50244 -Node: man50608 -Ref: #man50705 -Node: print51110 -Ref: #print51215 -Node: register54971 -Ref: #register55084 -Node: Custom register output59580 -Ref: #custom-register-output59711 -Node: stats61008 -Ref: #stats61114 -Node: test61995 -Ref: #test62082 -Node: ADD-ON COMMANDS62450 -Ref: #add-on-commands62562 -Node: Official add-ons63849 -Ref: #official-add-ons63991 -Node: api64078 -Ref: #api64169 -Node: ui64221 -Ref: #ui64322 -Node: web64380 -Ref: #web64471 -Node: Third party add-ons64517 -Ref: #third-party-add-ons64694 -Node: diff64829 -Ref: #diff64928 -Node: iadd65027 -Ref: #iadd65143 -Node: interest65226 -Ref: #interest65349 -Node: irr65444 -Ref: #irr65544 -Node: Experimental add-ons65622 -Ref: #experimental-add-ons65776 -Node: autosync66169 -Ref: #autosync66283 -Node: budget66522 -Ref: #budget66646 -Node: chart66712 -Ref: #chart66831 -Node: check66902 -Ref: #check67026 -Node: check-dates67093 -Ref: #check-dates67235 -Node: check-dupes67308 -Ref: #check-dupes67451 -Node: equity67528 -Ref: #equity67656 -Node: prices67775 -Ref: #prices67904 -Node: print-unique67959 -Ref: #print-unique68108 -Node: register-match68201 -Ref: #register-match68357 -Node: rewrite68455 -Ref: #rewrite68576 +Node: accounts26112 +Ref: #accounts26212 +Node: activity27194 +Ref: #activity27306 +Node: add27665 +Ref: #add27766 +Node: balance30424 +Ref: #balance30537 +Node: Flat mode33552 +Ref: #flat-mode33679 +Node: Depth limited balance reports34099 +Ref: #depth-limited-balance-reports34302 +Node: Multicolumn balance reports34722 +Ref: #multicolumn-balance-reports34933 +Node: Custom balance output39581 +Ref: #custom-balance-output39765 +Node: Colour support41858 +Ref: #colour-support42019 +Node: Output destination42192 +Ref: #output-destination42350 +Node: CSV output42620 +Ref: #csv-output42739 +Node: balancesheet43136 +Ref: #balancesheet43264 +Node: cashflow45171 +Ref: #cashflow45288 +Node: help47156 +Ref: #help47268 +Node: incomestatement48098 +Ref: #incomestatement48227 +Node: man50499 +Ref: #man50605 +Node: print51014 +Ref: #print51119 +Node: register54875 +Ref: #register54988 +Node: Custom register output59484 +Ref: #custom-register-output59615 +Node: stats60912 +Ref: #stats61018 +Node: test61899 +Ref: #test61986 +Node: ADD-ON COMMANDS62354 +Ref: #add-on-commands62466 +Node: Official add-ons63753 +Ref: #official-add-ons63895 +Node: api63982 +Ref: #api64073 +Node: ui64125 +Ref: #ui64226 +Node: web64284 +Ref: #web64375 +Node: Third party add-ons64421 +Ref: #third-party-add-ons64598 +Node: diff64733 +Ref: #diff64832 +Node: iadd64931 +Ref: #iadd65047 +Node: interest65130 +Ref: #interest65253 +Node: irr65348 +Ref: #irr65448 +Node: Experimental add-ons65526 +Ref: #experimental-add-ons65680 +Node: autosync66073 +Ref: #autosync66187 +Node: budget66426 +Ref: #budget66550 +Node: chart66616 +Ref: #chart66735 +Node: check66806 +Ref: #check66930 +Node: check-dates66997 +Ref: #check-dates67139 +Node: check-dupes67212 +Ref: #check-dupes67355 +Node: equity67432 +Ref: #equity67560 +Node: prices67679 +Ref: #prices67808 +Node: print-unique67863 +Ref: #print-unique68012 +Node: register-match68105 +Ref: #register-match68261 +Node: rewrite68359 +Ref: #rewrite68480  End Tag Table diff --git a/hledger/doc/hledger.1.txt b/hledger/doc/hledger.1.txt index f897efabd..1f6ed6c06 100644 --- a/hledger/doc/hledger.1.txt +++ b/hledger/doc/hledger.1.txt @@ -1286,16 +1286,19 @@ COMMANDS help Show any of the hledger manuals. - The help command displays any of the main hledger man pages. (Unlike - hledger --help, which displays only the hledger man page.) Run it with - no arguments to list available topics (their names are shortened for - easier typing), and run hledger help TOPIC to select one. The output - is similar to a man page, but fixed width. It may be long, so you may - wish to pipe it into a pager. See also info and man. + The help command displays any of the main hledger manuals, in one of + several ways. Run it with no argument to list the manuals (their names + are shortened for easier typing), and run hledger help MANUAL to select + one. + + hledger help will choose one of these docs viewers, in order of prefer- + ence: info, man, $PAGER, less, stdout (and it always prints on stdout + when piped). Or you can force a particular viewer with the --info, + --man, --pager, --cat flags. $ hledger help - Choose a topic, eg: hledger help cli - cli, ui, web, api, journal, csv, timeclock, timedot + Please choose a manual: + hledger help cli|ui|web|api|journal|csv|timeclock|timedot $ hledger help cli | less @@ -1307,9 +1310,7 @@ COMMANDS hledger - a command-line accounting tool SYNOPSIS - hledger [-f FILE] COMMAND [OPTIONS] [CMDARGS] - hledger [-f FILE] ADDONCMD -- [OPTIONS] [CMDARGS] - : + hledger [-f FILE] COMMAND [OPTIONS] [ARGS] incomestatement Show an income statement. Alias: is. @@ -1318,7 +1319,7 @@ COMMANDS show balance change in each period (default) --cumulative - show balance change accumulated across periods (in multicolumn + show balance change accumulated across periods (in multicolumn reports), instead of changes during periods -H --historical @@ -1349,8 +1350,8 @@ COMMANDS --format=LINEFORMAT in single-column balance reports: use this custom line format - This command displays a simple income statement. It currently assumes - that you have top-level accounts named income (or revenue) and expense + This command displays a simple income statement. It currently assumes + that you have top-level accounts named income (or revenue) and expense (plural forms also allowed.) $ hledger incomestatement @@ -1375,31 +1376,30 @@ COMMANDS 0 With a reporting interval, multiple columns will be shown, one for each - report period. Normally incomestatement shows revenues/expenses per - period, though as with multicolumn balance reports you can alter the + report period. Normally incomestatement shows revenues/expenses per + period, though as with multicolumn balance reports you can alter the report mode with --change/--cumulative/--historical. - info - Show any of the hledger manuals using info. + ... ## info Show any of the hledger manuals using info. - The info command displays any of the hledger reference manuals using - the info hypertextual documentation viewer. This can be a very effi- - cient way to browse large manuals. It requires the "info" program to + The info command displays any of the hledger reference manuals using + the info hypertextual documentation viewer. This can be a very effi- + cient way to browse large manuals. It requires the "info" program to be available in your PATH. - As with help, run it with no arguments to list available topics (manu- + As with help, run it with no arguments to list available topics (manu- als). man Show any of the hledger manuals using man. - The man command displays any of the hledger reference manuals using - man, the standard documentation viewer on unix systems. This will fit - the text to your terminal width, and probably invoke a pager automati- + The man command displays any of the hledger reference manuals using + man, the standard documentation viewer on unix systems. This will fit + the text to your terminal width, and probably invoke a pager automati- cally. It requires the "man" program to be available in your PATH. - As with help, run it with no arguments to list available topics (manu- - als). + As with help, run it with no arguments to list available topics (manu- + als). ``` print Show transactions from the journal. @@ -1408,14 +1408,14 @@ COMMANDS show all amounts explicitly -m STR --match=STR - show the transaction whose description is most similar to STR, + show the transaction whose description is most similar to STR, and is most recent -O FMT --output-format=FMT select the output format. Supported formats: txt, csv. -o FILE --output-file=FILE - write output to FILE. A file extension matching one of the + write output to FILE. A file extension matching one of the above formats selects that format. $ hledger print @@ -1443,23 +1443,23 @@ COMMANDS The print command displays full journal entries (transactions) from the journal file, tidily formatted. - As of hledger 1.2, print's output is always a valid hledger journal. - However it may not preserve all original content, eg it does not print + As of hledger 1.2, print's output is always a valid hledger journal. + However it may not preserve all original content, eg it does not print directives or inter-transaction comments. - Normally, transactions' implicit/explicit amount style is preserved: - when an amount is omitted in the journal, it will be omitted in the - output. You can use the -x/--explicit flag to make all amounts - explicit, which can be useful for troubleshooting or for making your - journal more readable and robust against data entry errors. Note, in - this mode postings with a multi-commodity amount (possible with an - implicit amount in a multi-commodity transaction) will be split into + Normally, transactions' implicit/explicit amount style is preserved: + when an amount is omitted in the journal, it will be omitted in the + output. You can use the -x/--explicit flag to make all amounts + explicit, which can be useful for troubleshooting or for making your + journal more readable and robust against data entry errors. Note, in + this mode postings with a multi-commodity amount (possible with an + implicit amount in a multi-commodity transaction) will be split into multiple single-commodity postings, for valid journal output. - With -B/--cost, amounts with transaction prices are converted to cost + With -B/--cost, amounts with transaction prices are converted to cost (using the transaction price). - The print command also supports output destination and CSV output. + The print command also supports output destination and CSV output. Here's an example of print's CSV output: $ hledger print -Ocsv @@ -1476,20 +1476,20 @@ COMMANDS "5","2008/12/31","","*","","pay off","","liabilities:debts","1","$","","1","","" "5","2008/12/31","","*","","pay off","","assets:bank:checking","-1","$","1","","","" - o There is one CSV record per posting, with the parent transaction's + o There is one CSV record per posting, with the parent transaction's fields repeated. o The "txnidx" (transaction index) field shows which postings belong to - the same transaction. (This number might change if transactions are - reordered within the file, files are parsed/included in a different + the same transaction. (This number might change if transactions are + reordered within the file, files are parsed/included in a different order, etc.) - o The amount is separated into "commodity" (the symbol) and "amount" + o The amount is separated into "commodity" (the symbol) and "amount" (numeric quantity) fields. o The numeric amount is repeated in either the "credit" or "debit" col- - umn, for convenience. (Those names are not accurate in the account- - ing sense; it just puts negative amounts under credit and zero or + umn, for convenience. (Those names are not accurate in the account- + ing sense; it just puts negative amounts under credit and zero or greater amounts under debit.) register @@ -1499,7 +1499,7 @@ COMMANDS show running total from report start date (default) -H --historical - show historical running total/balance (includes postings before + show historical running total/balance (includes postings before report start date) -A --average @@ -1510,18 +1510,18 @@ COMMANDS show postings' siblings instead -w N --width=N - set output width (default: terminal width or COLUMNS. -wN,M + set output width (default: terminal width or COLUMNS. -wN,M sets description width as well) -O FMT --output-format=FMT select the output format. Supported formats: txt, csv. -o FILE --output-file=FILE - write output to FILE. A file extension matching one of the + write output to FILE. A file extension matching one of the above formats selects that format. The register command displays postings, one per line, and their running - total. This is typically used with a query selecting a particular + total. This is typically used with a query selecting a particular account, to see that account's activity: $ hledger register checking @@ -1530,8 +1530,8 @@ COMMANDS 2008/06/02 save assets:bank:checking $-1 $1 2008/12/31 pay off assets:bank:checking $-1 0 - The --historical/-H flag adds the balance from any undisplayed prior - postings to the running total. This is useful when you want to see + The --historical/-H flag adds the balance from any undisplayed prior + postings to the running total. This is useful when you want to see only recent activity, with a historically accurate running balance: $ hledger register checking -b 2008/6 --historical @@ -1541,23 +1541,23 @@ COMMANDS The --depth option limits the amount of sub-account detail displayed. - The --average/-A flag shows the running average posting amount instead + The --average/-A flag shows the running average posting amount instead of the running total (so, the final number displayed is the average for - the whole report period). This flag implies --empty (see below). It - is affected by --historical. It works best when showing just one + the whole report period). This flag implies --empty (see below). It + is affected by --historical. It works best when showing just one account and one commodity. - The --related/-r flag shows the other postings in the transactions of + The --related/-r flag shows the other postings in the transactions of the postings which would normally be shown. - With a reporting interval, register shows summary postings, one per + With a reporting interval, register shows summary postings, one per interval, aggregating the postings to each account: $ hledger register --monthly income 2008/01 income:salary $-1 $-1 2008/06 income:gifts $-1 $-2 - Periods with no activity, and summary postings with a zero amount, are + Periods with no activity, and summary postings with a zero amount, are not shown by default; use the --empty/-E flag to see them: $ hledger register --monthly income -E @@ -1574,7 +1574,7 @@ COMMANDS 2008/11 0 $-2 2008/12 0 $-2 - Often, you'll want to see just one line per interval. The --depth + Often, you'll want to see just one line per interval. The --depth option helps with this, causing subaccounts to be aggregated: $ hledger register --monthly assets --depth 1h @@ -1582,19 +1582,19 @@ COMMANDS 2008/06 assets $-1 0 2008/12 assets $-1 $-1 - Note when using report intervals, if you specify start/end dates these - will be adjusted outward if necessary to contain a whole number of - intervals. This ensures that the first and last intervals are full + Note when using report intervals, if you specify start/end dates these + will be adjusted outward if necessary to contain a whole number of + intervals. This ensures that the first and last intervals are full length and comparable to the others in the report. Custom register output - register uses the full terminal width by default, except on windows. - You can override this by setting the COLUMNS environment variable (not + register uses the full terminal width by default, except on windows. + You can override this by setting the COLUMNS environment variable (not a bash shell variable) or by using the --width/-w option. - The description and account columns normally share the space equally - (about half of (width - 40) each). You can adjust this by adding a - description width as part of --width's argument, comma-separated: + The description and account columns normally share the space equally + (about half of (width - 40) each). You can adjust this by adding a + description width as part of --width's argument, comma-separated: --width W,D . Here's a diagram: <--------------------------------- width (W) ----------------------------------> @@ -1610,14 +1610,14 @@ COMMANDS $ hledger reg -w 100,40 # set overall width 100, description width 40 $ hledger reg -w $COLUMNS,40 # use terminal width, and set description width - The register command also supports the -o/--output-file and -O/--out- + The register command also supports the -o/--output-file and -O/--out- put-format options for controlling output destination and CSV output. stats Show some journal statistics. -o FILE --output-file=FILE - write output to FILE. A file extension matching one of the + write output to FILE. A file extension matching one of the above formats selects that format. $ hledger stats @@ -1632,8 +1632,8 @@ COMMANDS Accounts : 8 (depth 3) Commodities : 1 ($) - The stats command displays summary information for the whole journal, - or a matched part of it. With a reporting interval, it shows a report + The stats command displays summary information for the whole journal, + or a matched part of it. With a reporting interval, it shows a report for each report period. The stats command also supports -o/--output-file for controlling output @@ -1645,34 +1645,34 @@ COMMANDS $ hledger test Cases: 74 Tried: 74 Errors: 0 Failures: 0 - This command runs hledger's built-in unit tests and displays a quick + This command runs hledger's built-in unit tests and displays a quick report. With a regular expression argument, it selects only tests with matching names. It's mainly used in development, but it's also nice to be able to check your hledger executable for smoke at any time. ADD-ON COMMANDS - hledger also searches for external add-on commands, and will include + hledger also searches for external add-on commands, and will include these in the commands list. These are programs or scripts in your PATH - whose name starts with hledger- and ends with a recognised file exten- + whose name starts with hledger- and ends with a recognised file exten- sion (currently: no extension, bat,com,exe, hs,lhs,pl,py,rb,rkt,sh). - Add-ons can be invoked like any hledger command, but there are a few + Add-ons can be invoked like any hledger command, but there are a few things to be aware of. Eg if the hledger-web add-on is installed, o hledger -h web shows hledger's help, while hledger web -h shows hledger-web's help. - o Flags specific to the add-on must have a preceding -- to hide them - from hledger. So hledger web --serve --port 9000 will be rejected; + o Flags specific to the add-on must have a preceding -- to hide them + from hledger. So hledger web --serve --port 9000 will be rejected; you must use hledger web -- --serve --port 9000. - o You can always run add-ons directly if preferred: + o You can always run add-ons directly if preferred: hledger-web --serve --port 9000. - Add-ons are a relatively easy way to add local features or experiment - with new ideas. They can be written in any language, but haskell - scripts have a big advantage: they can use the same hledger (and - haskell) library functions that built-in commands do, for command-line + Add-ons are a relatively easy way to add local features or experiment + with new ideas. They can be written in any language, but haskell + scripts have a big advantage: they can use the same hledger (and + haskell) library functions that built-in commands do, for command-line options, journal parsing, reporting, etc. Here are some hledger add-ons available: @@ -1690,7 +1690,7 @@ ADD-ON COMMANDS hledger-web provides a simple web interface. Third party add-ons - These are maintained separately, and usually updated shortly after a + These are maintained separately, and usually updated shortly after a hledger release. diff @@ -1698,7 +1698,7 @@ ADD-ON COMMANDS journal file and another. iadd - hledger-iadd is a curses-style, more interactive replacement for the + hledger-iadd is a curses-style, more interactive replacement for the add command. interest @@ -1706,19 +1706,19 @@ ADD-ON COMMANDS ing to various schemes. irr - hledger-irr calculates the internal rate of return of an investment + hledger-irr calculates the internal rate of return of an investment account. Experimental add-ons - These are available in source form in the hledger repo's bin/ direc- + These are available in source form in the hledger repo's bin/ direc- tory; installing them is pretty easy. They may be less mature and doc- - umented than built-in commands. Reading and tweaking these is a good + umented than built-in commands. Reading and tweaking these is a good way to start making your own! autosync hledger-autosync is a symbolic link for easily running ledger-autosync, - if installed. ledger-autosync does deduplicating conversion of OFX - data and some CSV formats, and can also download the data if your bank + if installed. ledger-autosync does deduplicating conversion of OFX + data and some CSV formats, and can also download the data if your bank offers OFX Direct Connect. budget @@ -1734,18 +1734,18 @@ ADD-ON COMMANDS hledger-check-dates.hs checks that journal entries are ordered by date. check-dupes - hledger-check-dupes.hs checks for account names sharing the same leaf + hledger-check-dupes.hs checks for account names sharing the same leaf name. equity - hledger-equity.hs prints balance-resetting transactions, useful for + hledger-equity.hs prints balance-resetting transactions, useful for bringing account balances across file boundaries. prices hledger-prices.hs prints all prices from the journal. print-unique - hledger-print-unique.hs prints transactions which do not reuse an + hledger-print-unique.hs prints transactions which do not reuse an already-seen description. register-match @@ -1757,21 +1757,21 @@ ADD-ON COMMANDS tions. ENVIRONMENT - COLUMNS The screen width used by the register command. Default: the + COLUMNS The screen width used by the register command. Default: the full terminal width. LEDGER_FILE The journal file path when not specified with -f. Default: - ~/.hledger.journal (on windows, perhaps C:/Users/USER/.hledger.jour- + ~/.hledger.journal (on windows, perhaps C:/Users/USER/.hledger.jour- nal). FILES - Reads data from one or more files in hledger journal, timeclock, time- - dot, or CSV format specified with -f, or $LEDGER_FILE, or - $HOME/.hledger.journal (on windows, perhaps + Reads data from one or more files in hledger journal, timeclock, time- + dot, or CSV format specified with -f, or $LEDGER_FILE, or + $HOME/.hledger.journal (on windows, perhaps C:/Users/USER/.hledger.journal). BUGS - The need to precede addon command options with -- when invoked from + The need to precede addon command options with -- when invoked from hledger is awkward. When input data contains non-ascii characters, a suitable system locale @@ -1784,33 +1784,33 @@ BUGS In a Cygwin/MSYS/Mintty window, the tab key is not supported in hledger add. - Not all of Ledger's journal file syntax is supported. See file format + Not all of Ledger's journal file syntax is supported. See file format differences. - On large data files, hledger is slower and uses more memory than + On large data files, hledger is slower and uses more memory than Ledger. TROUBLESHOOTING - Here are some issues you might encounter when you run hledger (and - remember you can also seek help from the IRC channel, mail list or bug + Here are some issues you might encounter when you run hledger (and + remember you can also seek help from the IRC channel, mail list or bug tracker): Successfully installed, but "No command 'hledger' found" stack and cabal install binaries into a special directory, which should - be added to your PATH environment variable. Eg on unix-like systems, + be added to your PATH environment variable. Eg on unix-like systems, that is ~/.local/bin and ~/.cabal/bin respectively. I set a custom LEDGER_FILE, but hledger is still using the default file - LEDGER_FILE should be a real environment variable, not just a shell - variable. The command env | grep LEDGER_FILE should show it. You may + LEDGER_FILE should be a real environment variable, not just a shell + variable. The command env | grep LEDGER_FILE should show it. You may need to use export. Here's an explanation. - "Illegal byte sequence" or "Invalid or incomplete multibyte or wide + "Illegal byte sequence" or "Invalid or incomplete multibyte or wide character" errors In order to handle non-ascii letters and symbols (like ), hledger needs an appropriate locale. This is usually configured system-wide; you can also configure it temporarily. The locale may need to be one that sup- - ports UTF-8, if you built hledger with GHC < 7.2 (or possibly always, + ports UTF-8, if you built hledger with GHC < 7.2 (or possibly always, I'm not sure yet). Here's an example of setting the locale temporarily, on ubuntu @@ -1829,7 +1829,7 @@ TROUBLESHOOTING $ echo "export LANG=en_US.UTF-8" >>~/.bash_profile $ bash --login - If we preferred to use eg fr_FR.utf8, we might have to install that + If we preferred to use eg fr_FR.utf8, we might have to install that first: $ apt-get install language-pack-fr @@ -1850,7 +1850,7 @@ TROUBLESHOOTING REPORTING BUGS - 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) @@ -1864,7 +1864,7 @@ COPYRIGHT SEE ALSO - 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- dot(5), ledger(1)