hledger 1.16.1 → 1.16.2
raw patch · 56 files changed
+982/−857 lines, 56 filesdep ~hledger-libdep ~megaparsecPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: hledger-lib, megaparsec
API changes (from Hackage documentation)
Files
- CHANGES.md +6/−1
- Hledger/Cli/CliOptions.hs +3/−3
- Hledger/Cli/Commands/Accounts.txt +1/−1
- Hledger/Cli/Commands/Activity.txt +1/−1
- Hledger/Cli/Commands/Add.txt +1/−1
- Hledger/Cli/Commands/Balance.txt +1/−1
- Hledger/Cli/Commands/Balancesheet.txt +1/−1
- Hledger/Cli/Commands/Balancesheetequity.txt +1/−1
- Hledger/Cli/Commands/Cashflow.txt +1/−1
- Hledger/Cli/Commands/Checkdates.txt +1/−1
- Hledger/Cli/Commands/Checkdupes.txt +1/−1
- Hledger/Cli/Commands/Close.txt +8/−7
- Hledger/Cli/Commands/Commodities.txt +1/−1
- Hledger/Cli/Commands/Descriptions.txt +1/−1
- Hledger/Cli/Commands/Diff.txt +1/−1
- Hledger/Cli/Commands/Files.txt +1/−1
- Hledger/Cli/Commands/Help.txt +1/−1
- Hledger/Cli/Commands/Import.txt +1/−1
- Hledger/Cli/Commands/Incomestatement.txt +1/−1
- Hledger/Cli/Commands/Notes.txt +1/−1
- Hledger/Cli/Commands/Payees.txt +1/−1
- Hledger/Cli/Commands/Prices.txt +1/−1
- Hledger/Cli/Commands/Print.txt +1/−1
- Hledger/Cli/Commands/Printunique.txt +1/−1
- Hledger/Cli/Commands/Register.txt +2/−2
- Hledger/Cli/Commands/Registermatch.txt +1/−1
- Hledger/Cli/Commands/Rewrite.txt +1/−1
- Hledger/Cli/Commands/Roi.txt +1/−1
- Hledger/Cli/Commands/Stats.txt +1/−1
- Hledger/Cli/Commands/Tags.txt +1/−1
- Hledger/Cli/Commands/Test.txt +1/−1
- embeddedfiles/hledger-ui.1 +37/−37
- embeddedfiles/hledger-ui.info +7/−2
- embeddedfiles/hledger-ui.txt +1/−1
- embeddedfiles/hledger-web.1 +38/−38
- embeddedfiles/hledger-web.info +7/−2
- embeddedfiles/hledger-web.txt +1/−1
- embeddedfiles/hledger.1 +59/−59
- embeddedfiles/hledger.info +84/−78
- embeddedfiles/hledger.txt +181/−180
- embeddedfiles/hledger_csv.5 +30/−1
- embeddedfiles/hledger_csv.info +76/−44
- embeddedfiles/hledger_csv.txt +47/−28
- embeddedfiles/hledger_journal.5 +1/−1
- embeddedfiles/hledger_journal.info +7/−2
- embeddedfiles/hledger_journal.txt +1/−1
- embeddedfiles/hledger_timeclock.5 +2/−2
- embeddedfiles/hledger_timeclock.info +7/−2
- embeddedfiles/hledger_timeclock.txt +4/−4
- embeddedfiles/hledger_timedot.5 +1/−1
- embeddedfiles/hledger_timedot.info +7/−2
- embeddedfiles/hledger_timedot.txt +1/−1
- hledger.1 +59/−59
- hledger.cabal +13/−13
- hledger.info +84/−78
- hledger.txt +181/−180
CHANGES.md view
@@ -1,8 +1,13 @@ User-visible changes in the hledger command line tool and library. -# 1.16.1 2019-12-03+# 1.16.2 2020-01-14 +- add support for megaparsec 8 (#1175) +- close: mention --close-to/--open-from in docs+++# 1.16.1 2019-12-03 - Drop unnecessary mtl-compat dependency
Hledger/Cli/CliOptions.hs view
@@ -302,9 +302,9 @@ -- -- - First line: the command name then any aliases, as one or more space or comma-separated words ----- - Second line to a line containing just _FLAGS_, or the end: the short help+-- - Second line to a line containing just _FLAGS, or the end: the short help ----- - Any lines after _FLAGS_: the long help (split into lines for cmdargs)+-- - Any lines after _FLAGS: the long help (split into lines for cmdargs) -- -- The CLI help displays the short help, then the cmdargs-generated -- flags list, then the long help (which some day we might make@@ -318,7 +318,7 @@ (l:ls) -> Just (names, shorthelp, longhelplines) where names = words $ map (\c -> if c `elem` [',','\\'] then ' ' else c) l- (shorthelpls, longhelpls) = break (== "_FLAGS_") ls+ (shorthelpls, longhelpls) = break (== "_FLAGS") ls shorthelp = unlines $ reverse $ dropWhile null $ reverse shorthelpls longhelplines = dropWhile null $ drop 1 longhelpls
Hledger/Cli/Commands/Accounts.txt view
@@ -1,7 +1,7 @@ accounts, a Show account names. -_FLAGS_+_FLAGS This command lists account names, either declared with account directives (--declared), posted to (--used), or both (the default). With
Hledger/Cli/Commands/Activity.txt view
@@ -1,7 +1,7 @@ activity Show an ascii barchart of posting counts per interval. -_FLAGS_+_FLAGS The activity command displays an ascii histogram showing transaction counts by day, week, month or other reporting interval (by day is the
Hledger/Cli/Commands/Add.txt view
@@ -1,7 +1,7 @@ add Prompt for transactions and add them to the journal. -_FLAGS_+_FLAGS Many hledger users edit their journals directly with a text editor, or generate them from CSV. For more interactive data entry, there is the
Hledger/Cli/Commands/Balance.txt view
@@ -1,7 +1,7 @@ balance, bal, b Show accounts and their balances. -_FLAGS_+_FLAGS The balance command is hledger's most versatile command. Note, despite the name, it is not always used for showing real-world account balances;
Hledger/Cli/Commands/Balancesheet.txt view
@@ -8,7 +8,7 @@ (like conventional financial statements, unlike balance/print/register) (experimental). -_FLAGS_+_FLAGS Example:
Hledger/Cli/Commands/Balancesheetequity.txt view
@@ -2,7 +2,7 @@ Just like balancesheet, but also reports Equity (which it assumes is under a top-level equity account). -_FLAGS_+_FLAGS Example:
Hledger/Cli/Commands/Cashflow.txt view
@@ -6,7 +6,7 @@ account balances with normal positive sign (like conventional financial statements, unlike balance/print/register) (experimental). -_FLAGS_+_FLAGS Example:
Hledger/Cli/Commands/Checkdates.txt view
@@ -4,4 +4,4 @@ unique. With a query, only matched transactions' dates are checked. Reads the default journal file, or another specified with -f. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Checkdupes.txt view
@@ -3,6 +3,6 @@ other words, two or more leaves that are categorized differently. Reads the default journal file, or another specified as an argument. -_FLAGS_+_FLAGS An example: http://stefanorodighiero.net/software/hledger-dupes.html
Hledger/Cli/Commands/Close.txt view
@@ -5,12 +5,13 @@ file, or for closing out revenues/expenses to retained earnings at the end of a period. -_FLAGS_+_FLAGS -The closing transaction transfers balances to "equity:closing balances".-The opening transaction transfers balances from "equity:opening-balances". You can choose to print just one of the transactions by using-the --opening or --closing flag.+The closing transaction transfers balances to "equity:closing balances",+and the opening transaction transfers balances from "equity:opening+balances", or you can customise these with the --close-to and+--open-from options. You can choose to print just one of the+transactions by using the --opening or --closing flag. If you split your journal files by time (eg yearly), you will typically run this command at the end of the year, and save the closing@@ -50,8 +51,8 @@ Carrying asset/liability balances into a new file for 2019, all from command line: -_Warning: we use >> here to append; be careful not to type a single >-which would wipe your journal!_+Warning: we use >> here to append; be careful not to type a single >+which would wipe your journal! $ hledger close -f 2018.journal -e 2019 assets liabilities --opening >>2019.journal $ hledger close -f 2018.journal -e 2019 assets liabilities --closing >>2018.journal
Hledger/Cli/Commands/Commodities.txt view
@@ -1,4 +1,4 @@ commodities List all commodity/currency symbols used or declared in the journal. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Descriptions.txt view
@@ -1,6 +1,6 @@ descriptions Show descriptions. -_FLAGS_+_FLAGS This command lists all descriptions that appear in transactions.
Hledger/Cli/Commands/Diff.txt view
@@ -14,7 +14,7 @@ the account balance, you can compare the bank data with your journal to find out the cause. -_FLAGS_+_FLAGS Examples:
Hledger/Cli/Commands/Files.txt view
@@ -2,4 +2,4 @@ List all files included in the journal. With a REGEX argument, only file names matching the regular expression (case sensitive) are shown. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Help.txt view
@@ -1,7 +1,7 @@ help Show any of the hledger manuals. -_FLAGS_+_FLAGS The help command displays any of the main hledger manuals, in one of several ways. Run it with no argument to list the manuals, or provide a
Hledger/Cli/Commands/Import.txt view
@@ -4,7 +4,7 @@ that would be added. Or with --catchup, just mark all of the FILEs' transactions as imported, without actually importing any. -_FLAGS_+_FLAGS The input files are specified as arguments - no need to write -f before each one. So eg to add new transactions from all CSV files to the main
Hledger/Cli/Commands/Incomestatement.txt view
@@ -6,7 +6,7 @@ normal positive sign (like conventional financial statements, unlike balance/print/register) (experimental). -_FLAGS_+_FLAGS This command displays a simple income statement. It currently assumes that you have top-level accounts named income (or revenue) and expense
Hledger/Cli/Commands/Notes.txt view
@@ -1,6 +1,6 @@ notes Show notes. -_FLAGS_+_FLAGS This command lists all notes that appear in transactions.
Hledger/Cli/Commands/Payees.txt view
@@ -1,6 +1,6 @@ payees Show payee names. -_FLAGS_+_FLAGS This command lists all payee names that appear in transactions.
Hledger/Cli/Commands/Prices.txt view
@@ -5,4 +5,4 @@ Prices (and postings providing prices) can be filtered by a query. Price amounts are always displayed with their full precision. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Print.txt view
@@ -1,7 +1,7 @@ print, txns, p Show transaction journal entries, sorted by date. -_FLAGS_+_FLAGS The print command displays full journal entries (transactions) from the journal file in date order, tidily formatted. With --date2, transactions
Hledger/Cli/Commands/Printunique.txt view
@@ -1,7 +1,7 @@ print-unique Print transactions which do not reuse an already-seen description. -_FLAGS_+_FLAGS Example:
Hledger/Cli/Commands/Register.txt view
@@ -1,7 +1,7 @@ register, reg, r Show postings and their running total. -_FLAGS_+_FLAGS The register command displays postings in date order, one per line, and their running total. This is typically used with a query selecting a@@ -32,7 +32,7 @@ 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. The --invert flag negates all amounts. For example, it can be used on an
Hledger/Cli/Commands/Registermatch.txt view
@@ -5,4 +5,4 @@ arguments) can be used to restrict the search space. Helps ledger-autosync detect already-seen transactions when importing. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Rewrite.txt view
@@ -3,7 +3,7 @@ For now the only rewrite available is adding new postings, like print --auto. -_FLAGS_+_FLAGS This is a start at a generic rewriter of transaction entries. It reads the default journal and prints the transactions, like print, but adds
Hledger/Cli/Commands/Roi.txt view
@@ -2,7 +2,7 @@ Shows the time-weighted (TWR) and money-weighted (IRR) rate of return on your investments. -_FLAGS_+_FLAGS This command assumes that you have account(s) that hold nothing but your investments and whenever you record current appraisal/valuation of these
Hledger/Cli/Commands/Stats.txt view
@@ -1,7 +1,7 @@ stats Show some journal statistics. -_FLAGS_+_FLAGS 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
Hledger/Cli/Commands/Tags.txt view
@@ -5,4 +5,4 @@ considered. With --values flag, the tags' unique values are listed instead. -_FLAGS_+_FLAGS
Hledger/Cli/Commands/Test.txt view
@@ -1,7 +1,7 @@ test Run built-in unit tests. -_FLAGS_+_FLAGS This command runs the unit tests built in to hledger and hledger-lib, printing the results on stdout. If any test fails, the exit code will be
embeddedfiles/hledger-ui.1 view
@@ -1,5 +1,5 @@ -.TH "hledger-ui" "1" "December 2019" "hledger-ui 1.16.1" "hledger User Manuals"+.TH "hledger-ui" "1" "January 2020" "hledger-ui 1.16.2" "hledger User Manuals" @@ -47,113 +47,113 @@ Any QUERYARGS are interpreted as a hledger search query which filters the data. .TP-.B \f[C]--watch\f[R]+\f[B]\f[CB]--watch\f[B]\f[R] watch for data and date changes and reload automatically .TP-.B \f[C]--theme=default|terminal|greenterm\f[R]+\f[B]\f[CB]--theme=default|terminal|greenterm\f[B]\f[R] use this custom display theme .TP-.B \f[C]--register=ACCTREGEX\f[R]+\f[B]\f[CB]--register=ACCTREGEX\f[B]\f[R] start in the (first) matched account\[aq]s register screen .TP-.B \f[C]--change\f[R]+\f[B]\f[CB]--change\f[B]\f[R] show period balances (changes) at startup instead of historical balances .TP-.B \f[C]-F --flat\f[R]+\f[B]\f[CB]-F --flat\f[B]\f[R] show accounts as a list (default) .TP-.B \f[C]-T --tree\f[R]+\f[B]\f[CB]-T --tree\f[B]\f[R] show accounts as a tree .TP-.B \f[C]--future\f[R]+\f[B]\f[CB]--future\f[B]\f[R] show transactions dated later than today (normally hidden) .PP hledger input options: .TP-.B \f[C]-f FILE --file=FILE\f[R]+\f[B]\f[CB]-f FILE --file=FILE\f[B]\f[R] use a different input file. For stdin, use - (default: \f[C]$LEDGER_FILE\f[R] or \f[C]$HOME/.hledger.journal\f[R]) .TP-.B \f[C]--rules-file=RULESFILE\f[R]+\f[B]\f[CB]--rules-file=RULESFILE\f[B]\f[R] Conversion rules file to use when reading CSV (default: FILE.rules) .TP-.B \f[C]--separator=CHAR\f[R]+\f[B]\f[CB]--separator=CHAR\f[B]\f[R] Field separator to expect when reading CSV (default: \[aq],\[aq]) .TP-.B \f[C]--alias=OLD=NEW\f[R]+\f[B]\f[CB]--alias=OLD=NEW\f[B]\f[R] rename accounts named OLD to NEW .TP-.B \f[C]--anon\f[R]+\f[B]\f[CB]--anon\f[B]\f[R] anonymize accounts and payees .TP-.B \f[C]--pivot FIELDNAME\f[R]+\f[B]\f[CB]--pivot FIELDNAME\f[B]\f[R] use some other field or tag for the account name .TP-.B \f[C]-I --ignore-assertions\f[R]+\f[B]\f[CB]-I --ignore-assertions\f[B]\f[R] ignore any failing balance assertions .PP hledger reporting options: .TP-.B \f[C]-b --begin=DATE\f[R]+\f[B]\f[CB]-b --begin=DATE\f[B]\f[R] include postings/txns on or after this date .TP-.B \f[C]-e --end=DATE\f[R]+\f[B]\f[CB]-e --end=DATE\f[B]\f[R] include postings/txns before this date .TP-.B \f[C]-D --daily\f[R]+\f[B]\f[CB]-D --daily\f[B]\f[R] multiperiod/multicolumn report by day .TP-.B \f[C]-W --weekly\f[R]+\f[B]\f[CB]-W --weekly\f[B]\f[R] multiperiod/multicolumn report by week .TP-.B \f[C]-M --monthly\f[R]+\f[B]\f[CB]-M --monthly\f[B]\f[R] multiperiod/multicolumn report by month .TP-.B \f[C]-Q --quarterly\f[R]+\f[B]\f[CB]-Q --quarterly\f[B]\f[R] multiperiod/multicolumn report by quarter .TP-.B \f[C]-Y --yearly\f[R]+\f[B]\f[CB]-Y --yearly\f[B]\f[R] multiperiod/multicolumn report by year .TP-.B \f[C]-p --period=PERIODEXP\f[R]+\f[B]\f[CB]-p --period=PERIODEXP\f[B]\f[R] set start date, end date, and/or reporting interval all at once using period expressions syntax .TP-.B \f[C]--date2\f[R]+\f[B]\f[CB]--date2\f[B]\f[R] match the secondary date instead (see command help for other effects) .TP-.B \f[C]-U --unmarked\f[R]+\f[B]\f[CB]-U --unmarked\f[B]\f[R] include only unmarked postings/txns (can combine with -P or -C) .TP-.B \f[C]-P --pending\f[R]+\f[B]\f[CB]-P --pending\f[B]\f[R] include only pending postings/txns .TP-.B \f[C]-C --cleared\f[R]+\f[B]\f[CB]-C --cleared\f[B]\f[R] include only cleared postings/txns .TP-.B \f[C]-R --real\f[R]+\f[B]\f[CB]-R --real\f[B]\f[R] include only non-virtual postings .TP-.B \f[C]-NUM --depth=NUM\f[R]+\f[B]\f[CB]-NUM --depth=NUM\f[B]\f[R] hide/aggregate accounts or postings more than NUM levels deep .TP-.B \f[C]-E --empty\f[R]+\f[B]\f[CB]-E --empty\f[B]\f[R] show items with zero amount, normally hidden (and vice-versa in hledger-ui/hledger-web) .TP-.B \f[C]-B --cost\f[R]+\f[B]\f[CB]-B --cost\f[B]\f[R] convert amounts to their cost at transaction time (using the transaction price, if any) .TP-.B \f[C]-V --value\f[R]+\f[B]\f[CB]-V --value\f[B]\f[R] convert amounts to their market value on the report end date (using the most recent applicable market price, if any) .TP-.B \f[C]--auto\f[R]+\f[B]\f[CB]--auto\f[B]\f[R] apply automated posting rules to modify transactions. .TP-.B \f[C]--forecast\f[R]+\f[B]\f[CB]--forecast\f[B]\f[R] apply periodic transaction rules to generate future transactions, to 6 months from now or report end date. .PP@@ -164,13 +164,13 @@ .PP hledger help options: .TP-.B \f[C]-h --help\f[R]+\f[B]\f[CB]-h --help\f[B]\f[R] show general usage (or after COMMAND, command usage) .TP-.B \f[C]--version\f[R]+\f[B]\f[CB]--version\f[B]\f[R] show version .TP-.B \f[C]--debug[=N]\f[R]+\f[B]\f[CB]--debug[=N]\f[B]\f[R] show debug output (levels 1-9, default: 1) .PP A \[at]FILE argument will be expanded to the contents of FILE, which
embeddedfiles/hledger-ui.info view
@@ -1,9 +1,9 @@-This is hledger-ui.info, produced by makeinfo version 6.5 from stdin.+This is hledger-ui.info, produced by makeinfo version 6.7 from stdin. File: hledger-ui.info, Node: Top, Next: OPTIONS, Up: (dir) -hledger-ui(1) hledger-ui 1.16.1+hledger-ui(1) hledger-ui 1.16.2 ******************************* hledger-ui is hledger's terminal interface, providing an efficient@@ -439,3 +439,8 @@ Ref: #error-screen14811 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger-ui.txt view
@@ -431,4 +431,4 @@ -hledger-ui 1.16.1 December 2019 hledger-ui(1)+hledger-ui 1.16.2 January 2020 hledger-ui(1)
embeddedfiles/hledger-web.1 view
@@ -1,5 +1,5 @@ -.TH "hledger-web" "1" "December 2019" "hledger-web 1.16.1" "hledger User Manuals"+.TH "hledger-web" "1" "January 2020" "hledger-web 1.16.2" "hledger User Manuals" @@ -51,123 +51,123 @@ Note: if invoking hledger-web as a hledger subcommand, write \f[C]--\f[R] before options, as shown in the synopsis above. .TP-.B \f[C]--serve\f[R]+\f[B]\f[CB]--serve\f[B]\f[R] serve and log requests, don\[aq]t browse or auto-exit .TP-.B \f[C]--serve-api\f[R]+\f[B]\f[CB]--serve-api\f[B]\f[R] like --serve, but serve only the JSON web API, without the server-side web UI .TP-.B \f[C]--host=IPADDR\f[R]+\f[B]\f[CB]--host=IPADDR\f[B]\f[R] listen on this IP address (default: 127.0.0.1) .TP-.B \f[C]--port=PORT\f[R]+\f[B]\f[CB]--port=PORT\f[B]\f[R] listen on this TCP port (default: 5000) .TP-.B \f[C]--base-url=URL\f[R]+\f[B]\f[CB]--base-url=URL\f[B]\f[R] set the base url (default: http://IPADDR:PORT). You would change this when sharing over the network, or integrating within a larger website. .TP-.B \f[C]--file-url=URL\f[R]+\f[B]\f[CB]--file-url=URL\f[B]\f[R] set the static files url (default: BASEURL/static). 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. .TP-.B \f[C]--capabilities=CAP[,CAP..]\f[R]+\f[B]\f[CB]--capabilities=CAP[,CAP..]\f[B]\f[R] enable the view, add, and/or manage capabilities (default: view,add) .TP-.B \f[C]--capabilities-header=HTTPHEADER\f[R]+\f[B]\f[CB]--capabilities-header=HTTPHEADER\f[B]\f[R] read capabilities to enable from a HTTP header, like X-Sandstorm-Permissions (default: disabled) .PP hledger input options: .TP-.B \f[C]-f FILE --file=FILE\f[R]+\f[B]\f[CB]-f FILE --file=FILE\f[B]\f[R] use a different input file. For stdin, use - (default: \f[C]$LEDGER_FILE\f[R] or \f[C]$HOME/.hledger.journal\f[R]) .TP-.B \f[C]--rules-file=RULESFILE\f[R]+\f[B]\f[CB]--rules-file=RULESFILE\f[B]\f[R] Conversion rules file to use when reading CSV (default: FILE.rules) .TP-.B \f[C]--separator=CHAR\f[R]+\f[B]\f[CB]--separator=CHAR\f[B]\f[R] Field separator to expect when reading CSV (default: \[aq],\[aq]) .TP-.B \f[C]--alias=OLD=NEW\f[R]+\f[B]\f[CB]--alias=OLD=NEW\f[B]\f[R] rename accounts named OLD to NEW .TP-.B \f[C]--anon\f[R]+\f[B]\f[CB]--anon\f[B]\f[R] anonymize accounts and payees .TP-.B \f[C]--pivot FIELDNAME\f[R]+\f[B]\f[CB]--pivot FIELDNAME\f[B]\f[R] use some other field or tag for the account name .TP-.B \f[C]-I --ignore-assertions\f[R]+\f[B]\f[CB]-I --ignore-assertions\f[B]\f[R] ignore any failing balance assertions .PP hledger reporting options: .TP-.B \f[C]-b --begin=DATE\f[R]+\f[B]\f[CB]-b --begin=DATE\f[B]\f[R] include postings/txns on or after this date .TP-.B \f[C]-e --end=DATE\f[R]+\f[B]\f[CB]-e --end=DATE\f[B]\f[R] include postings/txns before this date .TP-.B \f[C]-D --daily\f[R]+\f[B]\f[CB]-D --daily\f[B]\f[R] multiperiod/multicolumn report by day .TP-.B \f[C]-W --weekly\f[R]+\f[B]\f[CB]-W --weekly\f[B]\f[R] multiperiod/multicolumn report by week .TP-.B \f[C]-M --monthly\f[R]+\f[B]\f[CB]-M --monthly\f[B]\f[R] multiperiod/multicolumn report by month .TP-.B \f[C]-Q --quarterly\f[R]+\f[B]\f[CB]-Q --quarterly\f[B]\f[R] multiperiod/multicolumn report by quarter .TP-.B \f[C]-Y --yearly\f[R]+\f[B]\f[CB]-Y --yearly\f[B]\f[R] multiperiod/multicolumn report by year .TP-.B \f[C]-p --period=PERIODEXP\f[R]+\f[B]\f[CB]-p --period=PERIODEXP\f[B]\f[R] set start date, end date, and/or reporting interval all at once using period expressions syntax .TP-.B \f[C]--date2\f[R]+\f[B]\f[CB]--date2\f[B]\f[R] match the secondary date instead (see command help for other effects) .TP-.B \f[C]-U --unmarked\f[R]+\f[B]\f[CB]-U --unmarked\f[B]\f[R] include only unmarked postings/txns (can combine with -P or -C) .TP-.B \f[C]-P --pending\f[R]+\f[B]\f[CB]-P --pending\f[B]\f[R] include only pending postings/txns .TP-.B \f[C]-C --cleared\f[R]+\f[B]\f[CB]-C --cleared\f[B]\f[R] include only cleared postings/txns .TP-.B \f[C]-R --real\f[R]+\f[B]\f[CB]-R --real\f[B]\f[R] include only non-virtual postings .TP-.B \f[C]-NUM --depth=NUM\f[R]+\f[B]\f[CB]-NUM --depth=NUM\f[B]\f[R] hide/aggregate accounts or postings more than NUM levels deep .TP-.B \f[C]-E --empty\f[R]+\f[B]\f[CB]-E --empty\f[B]\f[R] show items with zero amount, normally hidden (and vice-versa in hledger-ui/hledger-web) .TP-.B \f[C]-B --cost\f[R]+\f[B]\f[CB]-B --cost\f[B]\f[R] convert amounts to their cost at transaction time (using the transaction price, if any) .TP-.B \f[C]-V --value\f[R]+\f[B]\f[CB]-V --value\f[B]\f[R] convert amounts to their market value on the report end date (using the most recent applicable market price, if any) .TP-.B \f[C]--auto\f[R]+\f[B]\f[CB]--auto\f[B]\f[R] apply automated posting rules to modify transactions. .TP-.B \f[C]--forecast\f[R]+\f[B]\f[CB]--forecast\f[B]\f[R] apply periodic transaction rules to generate future transactions, to 6 months from now or report end date. .PP@@ -178,13 +178,13 @@ .PP hledger help options: .TP-.B \f[C]-h --help\f[R]+\f[B]\f[CB]-h --help\f[B]\f[R] show general usage (or after COMMAND, command usage) .TP-.B \f[C]--version\f[R]+\f[B]\f[CB]--version\f[B]\f[R] show version .TP-.B \f[C]--debug[=N]\f[R]+\f[B]\f[CB]--debug[=N]\f[B]\f[R] show debug output (levels 1-9, default: 1) .PP A \[at]FILE argument will be expanded to the contents of FILE, which
embeddedfiles/hledger-web.info view
@@ -1,9 +1,9 @@-This is hledger-web.info, produced by makeinfo version 6.5 from stdin.+This is hledger-web.info, produced by makeinfo version 6.7 from stdin. File: hledger-web.info, Node: Top, Next: OPTIONS, Up: (dir) -hledger-web(1) hledger-web 1.16.1+hledger-web(1) hledger-web 1.16.2 ********************************* hledger-web is hledger's web interface. It starts a simple web@@ -352,3 +352,8 @@ Ref: #json-api9770 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger-web.txt view
@@ -357,4 +357,4 @@ -hledger-web 1.16.1 December 2019 hledger-web(1)+hledger-web 1.16.2 January 2020 hledger-web(1)
embeddedfiles/hledger.1 view
@@ -1,6 +1,6 @@ .\"t -.TH "hledger" "1" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger" "1" "January 2020" "hledger 1.16.2" "hledger User Manuals" @@ -159,101 +159,101 @@ .PP General help options: .TP-.B \f[C]-h --help\f[R]+\f[B]\f[CB]-h --help\f[B]\f[R] show general usage (or after COMMAND, command usage) .TP-.B \f[C]--version\f[R]+\f[B]\f[CB]--version\f[B]\f[R] show version .TP-.B \f[C]--debug[=N]\f[R]+\f[B]\f[CB]--debug[=N]\f[B]\f[R] show debug output (levels 1-9, default: 1) .PP General input options: .TP-.B \f[C]-f FILE --file=FILE\f[R]+\f[B]\f[CB]-f FILE --file=FILE\f[B]\f[R] use a different input file. For stdin, use - (default: \f[C]$LEDGER_FILE\f[R] or \f[C]$HOME/.hledger.journal\f[R]) .TP-.B \f[C]--rules-file=RULESFILE\f[R]+\f[B]\f[CB]--rules-file=RULESFILE\f[B]\f[R] Conversion rules file to use when reading CSV (default: FILE.rules) .TP-.B \f[C]--separator=CHAR\f[R]+\f[B]\f[CB]--separator=CHAR\f[B]\f[R] Field separator to expect when reading CSV (default: \[aq],\[aq]) .TP-.B \f[C]--alias=OLD=NEW\f[R]+\f[B]\f[CB]--alias=OLD=NEW\f[B]\f[R] rename accounts named OLD to NEW .TP-.B \f[C]--anon\f[R]+\f[B]\f[CB]--anon\f[B]\f[R] anonymize accounts and payees .TP-.B \f[C]--pivot FIELDNAME\f[R]+\f[B]\f[CB]--pivot FIELDNAME\f[B]\f[R] use some other field or tag for the account name .TP-.B \f[C]-I --ignore-assertions\f[R]+\f[B]\f[CB]-I --ignore-assertions\f[B]\f[R] ignore any failing balance assertions .PP General reporting options: .TP-.B \f[C]-b --begin=DATE\f[R]+\f[B]\f[CB]-b --begin=DATE\f[B]\f[R] include postings/txns on or after this date .TP-.B \f[C]-e --end=DATE\f[R]+\f[B]\f[CB]-e --end=DATE\f[B]\f[R] include postings/txns before this date .TP-.B \f[C]-D --daily\f[R]+\f[B]\f[CB]-D --daily\f[B]\f[R] multiperiod/multicolumn report by day .TP-.B \f[C]-W --weekly\f[R]+\f[B]\f[CB]-W --weekly\f[B]\f[R] multiperiod/multicolumn report by week .TP-.B \f[C]-M --monthly\f[R]+\f[B]\f[CB]-M --monthly\f[B]\f[R] multiperiod/multicolumn report by month .TP-.B \f[C]-Q --quarterly\f[R]+\f[B]\f[CB]-Q --quarterly\f[B]\f[R] multiperiod/multicolumn report by quarter .TP-.B \f[C]-Y --yearly\f[R]+\f[B]\f[CB]-Y --yearly\f[B]\f[R] multiperiod/multicolumn report by year .TP-.B \f[C]-p --period=PERIODEXP\f[R]+\f[B]\f[CB]-p --period=PERIODEXP\f[B]\f[R] set start date, end date, and/or reporting interval all at once using period expressions syntax .TP-.B \f[C]--date2\f[R]+\f[B]\f[CB]--date2\f[B]\f[R] match the secondary date instead (see command help for other effects) .TP-.B \f[C]-U --unmarked\f[R]+\f[B]\f[CB]-U --unmarked\f[B]\f[R] include only unmarked postings/txns (can combine with -P or -C) .TP-.B \f[C]-P --pending\f[R]+\f[B]\f[CB]-P --pending\f[B]\f[R] include only pending postings/txns .TP-.B \f[C]-C --cleared\f[R]+\f[B]\f[CB]-C --cleared\f[B]\f[R] include only cleared postings/txns .TP-.B \f[C]-R --real\f[R]+\f[B]\f[CB]-R --real\f[B]\f[R] include only non-virtual postings .TP-.B \f[C]-NUM --depth=NUM\f[R]+\f[B]\f[CB]-NUM --depth=NUM\f[B]\f[R] hide/aggregate accounts or postings more than NUM levels deep .TP-.B \f[C]-E --empty\f[R]+\f[B]\f[CB]-E --empty\f[B]\f[R] show items with zero amount, normally hidden (and vice-versa in hledger-ui/hledger-web) .TP-.B \f[C]-B --cost\f[R]+\f[B]\f[CB]-B --cost\f[B]\f[R] convert amounts to their cost at transaction time (using the transaction price, if any) .TP-.B \f[C]-V --value\f[R]+\f[B]\f[CB]-V --value\f[B]\f[R] convert amounts to their market value on the report end date (using the most recent applicable market price, if any) .TP-.B \f[C]--auto\f[R]+\f[B]\f[CB]--auto\f[B]\f[R] apply automated posting rules to modify transactions. .TP-.B \f[C]--forecast\f[R]+\f[B]\f[CB]--forecast\f[B]\f[R] apply periodic transaction rules to generate future transactions, to 6 months from now or report end date. .PP@@ -773,7 +773,7 @@ .PP .TS tab(@);-l l.+l r. T{ \f[C]-p \[dq]2009\[dq]\f[R] T}@T{@@ -1101,20 +1101,20 @@ The TYPE part basically selects either \[dq]cost\[dq], or \[dq]market value\[dq] plus a valuation date: .TP-.B \f[C]--value=cost\f[R]+\f[B]\f[CB]--value=cost\f[B]\f[R] Convert amounts to cost, using the prices recorded in transactions. .TP-.B \f[C]--value=end\f[R]+\f[B]\f[CB]--value=end\f[B]\f[R] Convert amounts to their value in a default valuation commodity, using market prices on the last day of the report period (or if unspecified, the journal\[aq]s end date); or in multiperiod reports, market prices on the last day of each subperiod. .TP-.B \f[C]--value=now\f[R]+\f[B]\f[CB]--value=now\f[B]\f[R] Convert amounts to their value in default valuation commodity using current market prices (as of when report is generated). .TP-.B \f[C]--value=YYYY-MM-DD\f[R]+\f[B]\f[CB]--value=YYYY-MM-DD\f[B]\f[R] Convert amounts to their value in default valuation commodity using market prices on this date. .PP@@ -1509,30 +1509,30 @@ .PP \f[B]Additional notes\f[R] .TP-.B \f[I]cost\f[R]+\f[I]cost\f[R] calculated using price(s) recorded in the transaction(s). .TP-.B \f[I]value\f[R]+\f[I]value\f[R] market value using available market price declarations, or the unchanged amount if no conversion rate can be found. .TP-.B \f[I]report start\f[R]+\f[I]report start\f[R] the first day of the report period specified with -b or -p or date:, otherwise today. .TP-.B \f[I]report or journal start\f[R]+\f[I]report or journal start\f[R] the first day of the report period specified with -b or -p or date:, otherwise the earliest transaction date in the journal, otherwise today. .TP-.B \f[I]report end\f[R]+\f[I]report end\f[R] the last day of the report period specified with -e or -p or date:, otherwise today. .TP-.B \f[I]report or journal end\f[R]+\f[I]report or journal end\f[R] the last day of the report period specified with -e or -p or date:, otherwise the latest transaction date in the journal, otherwise today. .TP-.B \f[I]report interval\f[R]+\f[I]report interval\f[R] a flag (-D/-W/-M/-Q/-Y) or period expression that activates the report\[aq]s multi-period mode (whether showing one or many subperiods). .SS Combining -B, -V, -X, --value@@ -1646,12 +1646,12 @@ Remember these can also be prefixed with \f[B]\f[CB]not:\f[B]\f[R], eg to exclude a particular subaccount. .TP-.B \f[B]\f[CB]REGEX\f[B], \f[CB]acct:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]REGEX\f[R]\f[B], \f[R]\f[C]acct:REGEX\f[R]\f[B]\f[R] match account names by this regular expression. (With no prefix, \f[C]acct:\f[R] is assumed.) same as above .TP-.B \f[B]\f[CB]amt:N, amt:<N, amt:<=N, amt:>N, amt:>=N\f[B]\f[R]+\f[B]\f[R]\f[C]amt:N, amt:<N, amt:<=N, amt:>N, amt:>=N\f[R]\f[B]\f[R] match postings with a single-commodity amount that is equal to, less than, or greater than N. (Multi-commodity amounts are not tested, and will always match.) The@@ -1659,10 +1659,10 @@ the two signed numbers are compared. Otherwise, the absolute magnitudes are compared, ignoring sign. .TP-.B \f[B]\f[CB]code:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]code:REGEX\f[R]\f[B]\f[R] match by transaction code (eg check number) .TP-.B \f[B]\f[CB]cur:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]cur:REGEX\f[R]\f[B]\f[R] match postings or transactions including any amounts whose currency/commodity symbol is fully matched by REGEX. (For a partial match, use \f[C].*REGEX.*\f[R]).@@ -1673,10 +1673,10 @@ \f[C]hledger print cur:\[aq]\[rs]$\[aq]\f[R] or \f[C]hledger print cur:\[rs]\[rs]$\f[R]. .TP-.B \f[B]\f[CB]desc:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]desc:REGEX\f[R]\f[B]\f[R] match transaction descriptions. .TP-.B \f[B]\f[CB]date:PERIODEXPR\f[B]\f[R]+\f[B]\f[R]\f[C]date:PERIODEXPR\f[R]\f[B]\f[R] match dates within the specified period. PERIODEXPR is a period expression (with no report interval). Examples: \f[C]date:2016\f[R], \f[C]date:thismonth\f[R],@@ -1684,27 +1684,27 @@ If the \f[C]--date2\f[R] command line flag is present, this matches secondary dates instead. .TP-.B \f[B]\f[CB]date2:PERIODEXPR\f[B]\f[R]+\f[B]\f[R]\f[C]date2:PERIODEXPR\f[R]\f[B]\f[R] match secondary dates within the specified period. .TP-.B \f[B]\f[CB]depth:N\f[B]\f[R]+\f[B]\f[R]\f[C]depth:N\f[R]\f[B]\f[R] match (or display, depending on command) accounts at or above this depth .TP-.B \f[B]\f[CB]note:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]note:REGEX\f[R]\f[B]\f[R] match transaction notes (part of description right of \f[C]|\f[R], or whole description when there\[aq]s no \f[C]|\f[R]) .TP-.B \f[B]\f[CB]payee:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]payee:REGEX\f[R]\f[B]\f[R] match transaction payee/payer names (part of description left of \f[C]|\f[R], or whole description when there\[aq]s no \f[C]|\f[R]) .TP-.B \f[B]\f[CB]real:, real:0\f[B]\f[R]+\f[B]\f[R]\f[C]real:, real:0\f[R]\f[B]\f[R] match real or virtual postings respectively .TP-.B \f[B]\f[CB]status:, status:!, status:*\f[B]\f[R]+\f[B]\f[R]\f[C]status:, status:!, status:*\f[R]\f[B]\f[R] match unmarked, pending, or cleared transactions respectively .TP-.B \f[B]\f[CB]tag:REGEX[=REGEX]\f[B]\f[R]+\f[B]\f[R]\f[C]tag:REGEX[=REGEX]\f[R]\f[B]\f[R] match by tag name, and optionally also by tag value. Note a tag: query is considered to match a transaction if it matches any of the postings.@@ -1714,7 +1714,7 @@ The following special search term is used automatically in hledger-web, only: .TP-.B \f[B]\f[CB]inacct:ACCTNAME\f[B]\f[R]+\f[B]\f[R]\f[C]inacct:ACCTNAME\f[R]\f[B]\f[R] tells hledger-web to show the transaction register for this account. Can be filtered further with \f[C]acct\f[R] etc. .PP@@ -2669,9 +2669,9 @@ end of a period. .PP The closing transaction transfers balances to \[dq]equity:closing-balances\[dq].-The opening transaction transfers balances from \[dq]equity:opening-balances\[dq].+balances\[dq], and the opening transaction transfers balances from+\[dq]equity:opening balances\[dq], or you can customise these with the+\f[C]--close-to\f[R] and \f[C]--open-from\f[R] options. You can choose to print just one of the transactions by using the \f[C]--opening\f[R] or \f[C]--closing\f[R] flag. .PP
embeddedfiles/hledger.info view
@@ -1,9 +1,9 @@-This is hledger.info, produced by makeinfo version 6.5 from stdin.+This is hledger.info, produced by makeinfo version 6.7 from stdin. File: hledger.info, Node: Top, Next: EXAMPLES, Up: (dir) -hledger(1) hledger 1.16.1+hledger(1) hledger 1.16.2 ************************* This is hledger's command-line interface (there are also terminal and@@ -2187,9 +2187,10 @@ end of a period. The closing transaction transfers balances to "equity:closing-balances". The opening transaction transfers balances from-"equity:opening balances". You can choose to print just one of the-transactions by using the '--opening' or '--closing' flag.+balances", and the opening transaction transfers balances from+"equity:opening balances", or you can customise these with the+'--close-to' and '--open-from' options. You can choose to print just+one of the transactions by using the '--opening' or '--closing' flag. If you split your journal files by time (eg yearly), you will typically run this command at the end of the year, and save the closing@@ -3290,78 +3291,83 @@ Ref: #check-dupes75909 Node: close76202 Ref: #close76316-Node: commodities79903-Ref: #commodities80030-Node: descriptions80112-Ref: #descriptions80240-Node: diff80421-Ref: #diff80527-Node: files81574-Ref: #files81674-Node: help81821-Ref: #help81921-Node: import83002-Ref: #import83116-Node: Importing balance assignments84009-Ref: #importing-balance-assignments84157-Node: incomestatement84806-Ref: #incomestatement84939-Node: notes86343-Ref: #notes86456-Node: payees86582-Ref: #payees86688-Node: prices86846-Ref: #prices86952-Node: print87293-Ref: #print87403-Node: print-unique91896-Ref: #print-unique92022-Node: register92307-Ref: #register92434-Node: Custom register output96606-Ref: #custom-register-output96735-Node: register-match97997-Ref: #register-match98131-Node: rewrite98482-Ref: #rewrite98597-Node: Re-write rules in a file100452-Ref: #re-write-rules-in-a-file100586-Node: Diff output format101796-Ref: #diff-output-format101965-Node: rewrite vs print --auto103057-Ref: #rewrite-vs.-print---auto103236-Node: roi103792-Ref: #roi103890-Node: stats104902-Ref: #stats105001-Node: tags105789-Ref: #tags105887-Node: test106181-Ref: #test106265-Node: ADD-ON COMMANDS107012-Ref: #add-on-commands107122-Node: Official add-ons108410-Ref: #official-add-ons108550-Node: ui108630-Ref: #ui108717-Node: web108771-Ref: #web108860-Node: Third party add-ons108906-Ref: #third-party-add-ons109081-Ref: #diff-1109240-Node: iadd109339-Ref: #iadd109449-Node: interest109531-Ref: #interest109652-Node: irr109747-Ref: #irr109845-Node: Experimental add-ons109976-Ref: #experimental-add-ons110128-Node: autosync110376-Ref: #autosync110487-Node: chart110726-Ref: #chart110845-Node: check110916-Ref: #check111018+Node: commodities79982+Ref: #commodities80109+Node: descriptions80191+Ref: #descriptions80319+Node: diff80500+Ref: #diff80606+Node: files81653+Ref: #files81753+Node: help81900+Ref: #help82000+Node: import83081+Ref: #import83195+Node: Importing balance assignments84088+Ref: #importing-balance-assignments84236+Node: incomestatement84885+Ref: #incomestatement85018+Node: notes86422+Ref: #notes86535+Node: payees86661+Ref: #payees86767+Node: prices86925+Ref: #prices87031+Node: print87372+Ref: #print87482+Node: print-unique91975+Ref: #print-unique92101+Node: register92386+Ref: #register92513+Node: Custom register output96685+Ref: #custom-register-output96814+Node: register-match98076+Ref: #register-match98210+Node: rewrite98561+Ref: #rewrite98676+Node: Re-write rules in a file100531+Ref: #re-write-rules-in-a-file100665+Node: Diff output format101875+Ref: #diff-output-format102044+Node: rewrite vs print --auto103136+Ref: #rewrite-vs.-print---auto103315+Node: roi103871+Ref: #roi103969+Node: stats104981+Ref: #stats105080+Node: tags105868+Ref: #tags105966+Node: test106260+Ref: #test106344+Node: ADD-ON COMMANDS107091+Ref: #add-on-commands107201+Node: Official add-ons108489+Ref: #official-add-ons108629+Node: ui108709+Ref: #ui108796+Node: web108850+Ref: #web108939+Node: Third party add-ons108985+Ref: #third-party-add-ons109160+Ref: #diff-1109319+Node: iadd109418+Ref: #iadd109528+Node: interest109610+Ref: #interest109731+Node: irr109826+Ref: #irr109924+Node: Experimental add-ons110055+Ref: #experimental-add-ons110207+Node: autosync110455+Ref: #autosync110566+Node: chart110805+Ref: #chart110924+Node: check110995+Ref: #check111097 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger.txt view
@@ -1926,50 +1926,51 @@ end of a period. The closing transaction transfers balances to "equity:closing bal-- ances". The opening transaction transfers balances from "equity:open-- ing balances". You can choose to print just one of the transactions by- using the --opening or --closing flag.+ ances", and the opening transaction transfers balances from "eq-+ uity:opening balances", or you can customise these with the --close-to+ and --open-from options. You can choose to print just one of the+ transactions by using the --opening or --closing flag. If you split your journal files by time (eg yearly), you will typically- run this command at the end of the year, and save the closing transac-- tion as last entry of the old file, and the opening transaction as the- first entry of the new file. This makes the files self contained, so- that correct balances are reported no matter which of them are loaded.- Ie, if you load just one file, the balances are initialised correctly;- or if you load several files, the redundant closing/opening transac-- tions cancel each other out. (They will show up in print or register- reports; you can exclude them with a query like not:desc:'(open-+ run this command at the end of the year, and save the closing transac-+ tion as last entry of the old file, and the opening transaction as the+ first entry of the new file. This makes the files self contained, so+ that correct balances are reported no matter which of them are loaded.+ Ie, if you load just one file, the balances are initialised correctly;+ or if you load several files, the redundant closing/opening transac-+ tions cancel each other out. (They will show up in print or register+ reports; you can exclude them with a query like not:desc:'(open- ing|closing) balances'.) If you're running a business, you might also use this command to "close- the books" at the end of an accounting period, transferring income- statement account balances to retained earnings. (You may want to+ the books" at the end of an accounting period, transferring income+ statement account balances to retained earnings. (You may want to change the equity account name to something like "equity:retained earn- ings".) - By default, the closing transaction is dated yesterday, the balances- are calculated as of end of yesterday, and the opening transaction is- dated today. To close on some other date, use: hledger close -e OPEN-- INGDATE. Eg, to close/open on the 2018/2019 boundary, use -e 2019.+ By default, the closing transaction is dated yesterday, the balances+ are calculated as of end of yesterday, and the opening transaction is+ dated today. To close on some other date, use: hledger close -e OPEN-+ INGDATE. Eg, to close/open on the 2018/2019 boundary, use -e 2019. You can also use -p or date:PERIOD (any starting date is ignored). - Both transactions will include balance assertions for the closed/re-+ Both transactions will include balance assertions for the closed/re- opened accounts. You probably shouldn't use status or realness filters- (like -C or -R or status:) with this command, or the generated balance- assertions will depend on these flags. Likewise, if you run this com-- mand with --auto, the balance assertions will probably always require+ (like -C or -R or status:) with this command, or the generated balance+ assertions will depend on these flags. Likewise, if you run this com-+ mand with --auto, the balance assertions will probably always require --auto. - When account balances have cost information (transaction prices), the- closing/opening transactions will preserve it, so that eg balance -B+ When account balances have cost information (transaction prices), the+ closing/opening transactions will preserve it, so that eg balance -B reports will not be affected. Examples: - Carrying asset/liability balances into a new file for 2019, all from+ Carrying asset/liability balances into a new file for 2019, all from command line: - Warning: we use >> here to append; be careful not to type a single >+ Warning: we use >> here to append; be careful not to type a single > which would wipe your journal! $ hledger close -f 2018.journal -e 2019 assets liabilities --opening >>2019.journal@@ -2018,18 +2019,18 @@ diff diff- Compares a particular account's transactions in two input files. It+ Compares a particular account's transactions in two input files. It shows any transactions to this account which are in one file but not in the other. More precisely, for each posting affecting this account in either file,- it looks for a corresponding posting in the other file which posts the- same amount to the same account (ignoring date, description, etc.)+ it looks for a corresponding posting in the other file which posts the+ same amount to the same account (ignoring date, description, etc.) Since postings not transactions are compared, this also works when mul- tiple bank transactions have been combined into a single journal entry. This is useful eg if you have downloaded an account's transactions from- your bank (eg as CSV data). When hledger and your bank disagree about+ your bank (eg as CSV data). When hledger and your bank disagree about the account balance, you can compare the bank data with your journal to find out the cause. @@ -2047,20 +2048,20 @@ files files- List all files included in the journal. With a REGEX argument, only+ List all files included in the journal. With a REGEX argument, only file names matching the regular expression (case sensitive) are shown. help help Show any of the hledger manuals. - The help command displays any of the main hledger manuals, in one of- several ways. Run it with no argument to list the manuals, or provide+ The help command displays any of the main hledger manuals, in one of+ several ways. Run it with no argument to list the manuals, or provide a full or partial manual name to select one. - hledger manuals are available in several formats. hledger help will- use the first of these display methods that it finds: info, man,- $PAGER, less, stdout (or when non-interactive, just stdout). You can+ hledger manuals are available in several formats. hledger help will+ use the first of these display methods that it finds: info, man,+ $PAGER, less, stdout (or when non-interactive, just stdout). You can force a particular viewer with the --info, --man, --pager, --cat flags. Examples:@@ -2087,9 +2088,9 @@ import import- Read new transactions added to each FILE since last run, and add them- to the main journal file. Or with --dry-run, just print the transac-- tions that would be added. Or with --catchup, just mark all of the+ Read new transactions added to each FILE since last run, and add them+ to the main journal file. Or with --dry-run, just print the transac-+ tions that would be added. Or with --catchup, just mark all of the FILEs' transactions as imported, without actually importing any. The input files are specified as arguments - no need to write -f before@@ -2100,36 +2101,36 @@ ing transactions are always added to the input files in increasing date order, and by saving .latest.FILE state files. - The --dry-run output is in journal format, so you can filter it, eg to+ The --dry-run output is in journal format, so you can filter it, eg to see only uncategorised transactions: $ hledger import --dry ... | hledger -f- print unknown --ignore-assertions Importing balance assignments- Entries added by import will have their posting amounts made explicit- (like hledger print -x). This means that any balance assignments in- imported files must be evaluated; but, imported files don't get to see- the main file's account balances. As a result, importing entries with+ Entries added by import will have their posting amounts made explicit+ (like hledger print -x). This means that any balance assignments in+ imported files must be evaluated; but, imported files don't get to see+ the main file's account balances. As a result, importing entries with balance assignments (eg from an institution that provides only balances- and not posting amounts) will probably generate incorrect posting+ and not posting amounts) will probably generate incorrect posting amounts. To avoid this problem, use print instead of import: $ hledger print IMPORTFILE [--new] >> $LEDGER_FILE - (If you think import should leave amounts implicit like print does,+ (If you think import should leave amounts implicit like print does, please test it and send a pull request.) incomestatement incomestatement, is- This command displays a simple income statement, showing revenues and- expenses during a period. It assumes that these accounts are under a- top-level revenue or income or expense account (case insensitive, plu-- ral forms also allowed). Note this report shows all account balances- with normal positive sign (like conventional financial statements, un-+ This command displays a simple income statement, showing revenues and+ expenses during a period. It assumes that these accounts are under a+ top-level revenue or income or expense account (case insensitive, plu-+ ral forms also allowed). Note this report shows all account balances+ with normal positive sign (like conventional financial statements, un- like balance/print/register) (experimental). - 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@@ -2154,12 +2155,12 @@ 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 mode with --change/--cumulative/--historical. Instead of abso-+ 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. Instead of abso- lute values percentages can be displayed with -%. - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. notes@@ -2187,10 +2188,10 @@ prices prices- Print market price directives from the journal. With --costs, also- print synthetic market prices based on transaction prices. With --in-- verted-costs, also print inverse prices based on transaction prices.- Prices (and postings providing prices) can be filtered by a query.+ Print market price directives from the journal. With --costs, also+ print synthetic market prices based on transaction prices. With --in-+ verted-costs, also print inverse prices based on transaction prices.+ Prices (and postings providing prices) can be filtered by a query. Price amounts are always displayed with their full precision. print@@ -2198,11 +2199,11 @@ Show transaction journal entries, sorted by date. The print command displays full journal entries (transactions) from the- journal file in date order, tidily formatted. With --date2, transac-+ journal file in date order, tidily formatted. With --date2, transac- tions are sorted by secondary date instead. print's output is always a valid hledger journal.- It preserves all transaction information, but it does not preserve di-+ It preserves all transaction information, but it does not preserve di- rectives or inter-transaction comments $ hledger print@@ -2228,39 +2229,39 @@ assets:bank:checking $-1 Normally, the journal entry's explicit or implicit amount style is pre-- served. Ie when an amount is omitted in the journal, it will be omit-- ted in the output. You can use the -x/--explicit flag to make all+ served. Ie when an amount is omitted in the journal, it will be omit-+ ted 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,- -x will cause postings with a multi-commodity amount (these can arise- when a multi-commodity transaction has an implicit amount) will be- split into multiple single-commodity postings, for valid journal out-+ -x will cause postings with a multi-commodity amount (these can arise+ when a multi-commodity transaction has an implicit amount) will be+ split into multiple single-commodity postings, for valid journal out- put. - With -B/--cost, amounts with transaction prices are converted to cost+ With -B/--cost, amounts with transaction prices are converted to cost using that price. This can be used for troubleshooting. - With -m/--match and a STR argument, print will show at most one trans-- action: the one one whose description is most similar to STR, and is- most recent. STR should contain at least two characters. If there is+ With -m/--match and a STR argument, print will show at most one trans-+ action: the one one whose description is most similar to STR, and is+ most recent. STR should contain at least two characters. If there is no similar-enough match, no transaction will be shown. With --new, for each FILE being read, hledger reads (and writes) a spe-- cial state file (.latest.FILE in the same directory), containing the- latest transaction date(s) that were seen last time FILE was read.- When this file is found, only transactions with newer dates (and new- transactions on the latest date) are printed. This is useful for ig-- noring already-seen entries in import data, such as downloaded CSV+ cial state file (.latest.FILE in the same directory), containing the+ latest transaction date(s) that were seen last time FILE was read.+ When this file is found, only transactions with newer dates (and new+ transactions on the latest date) are printed. This is useful for ig-+ noring already-seen entries in import data, such as downloaded CSV files. Eg: $ hledger -f bank1.csv print --new # shows transactions added since last print --new on this file - This assumes that transactions added to FILE always have same or in-- creasing dates, and that transactions on the same day do not get re-+ This assumes that transactions added to FILE always have same or in-+ creasing dates, and that transactions on the same day do not get re- ordered. See also the import command. - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. Here's an example of print's CSV output: $ hledger print -Ocsv@@ -2277,20 +2278,20 @@ "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.) print-unique@@ -2314,7 +2315,7 @@ Show postings and their running total. The register command displays postings in date order, one per line, and- their running total. This is typically used with a query selecting a+ their running total. This is typically used with a query selecting a particular account, to see that account's activity: $ hledger register checking@@ -2325,8 +2326,8 @@ With --date2, it shows and sorts by secondary date instead. - 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@@ -2336,18 +2337,18 @@ 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 ac-+ the whole report period). This flag implies --empty (see below). It+ is affected by --historical. It works best when showing just one ac- count 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. - The --invert flag negates all amounts. For example, it can be used on+ The --invert flag negates all amounts. For example, it can be used on an income account where amounts are normally displayed as negative num-- bers. It's also useful to show postings on the checking account to-+ bers. It's also useful to show postings on the checking account to- gether with the related account: $ hledger register --related --invert assets:checking@@ -2359,7 +2360,7 @@ 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@@ -2376,7 +2377,7 @@ 2008/11 0 $-2 2008/12 0 $-2 - Often, you'll want to see just one line per interval. The --depth op-+ Often, you'll want to see just one line per interval. The --depth op- tion helps with this, causing subaccounts to be aggregated: $ hledger register --monthly assets --depth 1h@@ -2384,17 +2385,17 @@ 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 in-- tervals. 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 in-+ tervals. 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+ The description and account columns normally share the space equally (about half of (width - 40) each). You can adjust this by adding a de- scription width as part of --width's argument, comma-separated: --width W,D . Here's a diagram (won't display correctly in --help):@@ -2412,27 +2413,27 @@ $ hledger reg -w 100,40 # set overall width 100, description width 40 $ hledger reg -w $COLUMNS,40 # use terminal width, & description width 40 - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. register-match register-match Print the one posting whose transaction description is closest to DESC,- in the style of the register command. If there are multiple equally- good matches, it shows the most recent. Query options (options, not- arguments) can be used to restrict the search space. Helps ledger-au-+ in the style of the register command. If there are multiple equally+ good matches, it shows the most recent. Query options (options, not+ arguments) can be used to restrict the search space. Helps ledger-au- tosync detect already-seen transactions when importing. rewrite rewrite Print all transactions, rewriting the postings of matched transactions.- For now the only rewrite available is adding new postings, like print+ For now the only rewrite available is adding new postings, like print --auto. This is a start at a generic rewriter of transaction entries. It reads- the default journal and prints the transactions, like print, but adds+ the default journal and prints the transactions, like print, but adds one or more specified postings to any transactions matching QUERY. The- posting amounts can be fixed, or a multiplier of the existing transac-+ posting amounts can be fixed, or a multiplier of the existing transac- tion's first posting amount. Examples:@@ -2448,7 +2449,7 @@ (reserve:grocery) *0.25 ; reserve 25% for grocery (reserve:) *0.25 ; reserve 25% for grocery - Note the single quotes to protect the dollar sign from bash, and the+ Note the single quotes to protect the dollar sign from bash, and the two spaces between account and amount. More:@@ -2458,16 +2459,16 @@ $ hledger rewrite -- expenses:gifts --add-posting '(budget:gifts) *-1"' $ hledger rewrite -- ^income --add-posting '(budget:foreign currency) *0.25 JPY; diversify' - Argument for --add-posting option is a usual posting of transaction- with an exception for amount specification. More precisely, you can+ Argument for --add-posting option is a usual posting of transaction+ with an exception for amount specification. More precisely, you can use '*' (star symbol) before the amount to indicate that that this is a- factor for an amount of original matched posting. If the amount in-+ factor for an amount of original matched posting. If the amount in- cludes a commodity name, the new posting amount will be in the new com-- modity; otherwise, it will be in the matched posting amount's commod-+ modity; otherwise, it will be in the matched posting amount's commod- ity. Re-write rules in a file- During the run this tool will execute so called "Automated Transac-+ During the run this tool will execute so called "Automated Transac- tions" found in any journal it process. I.e instead of specifying this operations in command line you can put them in a journal file. @@ -2482,7 +2483,7 @@ budget:gifts *-1 assets:budget *1 - Note that '=' (equality symbol) that is used instead of date in trans-+ Note that '=' (equality symbol) that is used instead of date in trans- actions you usually write. It indicates the query by which you want to match the posting to add new ones. @@ -2495,12 +2496,12 @@ --add-posting 'assets:budget *1' \ > rewritten-tidy-output.journal - It is important to understand that relative order of such entries in- journal is important. You can re-use result of previously added post-+ It is important to understand that relative order of such entries in+ journal is important. You can re-use result of previously added post- ings. Diff output format- To use this tool for batch modification of your journal files you may+ To use this tool for batch modification of your journal files you may find useful output in form of unified diff. $ hledger rewrite -- --diff -f examples/sample.journal '^income' --add-posting '(liabilities:tax) *.33'@@ -2524,10 +2525,10 @@ If you'll pass this through patch tool you'll get transactions contain- ing the posting that matches your query be updated. Note that multiple- files might be update according to list of input files specified via+ files might be update according to list of input files specified via --file options and include directives inside of these files. - Be careful. Whole transaction being re-formatted in a style of output+ Be careful. Whole transaction being re-formatted in a style of output from hledger print. See also:@@ -2535,48 +2536,48 @@ https://github.com/simonmichael/hledger/issues/99 rewrite vs. print --auto- This command predates print --auto, and currently does much the same+ This command predates print --auto, and currently does much the same thing, but with these differences: - o with multiple files, rewrite lets rules in any file affect all other- files. print --auto uses standard directive scoping; rules affect+ o with multiple files, rewrite lets rules in any file affect all other+ files. print --auto uses standard directive scoping; rules affect only child files. - o rewrite's query limits which transactions can be rewritten; all are+ o rewrite's query limits which transactions can be rewritten; all are printed. print --auto's query limits which transactions are printed. - o rewrite applies rules specified on command line or in the journal.+ o rewrite applies rules specified on command line or in the journal. print --auto applies rules specified in the journal. roi roi- Shows the time-weighted (TWR) and money-weighted (IRR) rate of return+ Shows the time-weighted (TWR) and money-weighted (IRR) rate of return on your investments. - This command assumes that you have account(s) that hold nothing but+ This command assumes that you have account(s) that hold nothing but your investments and whenever you record current appraisal/valuation of these investments you offset unrealized profit and loss into account(s) that, again, hold nothing but unrealized profit and loss. - Any transactions affecting balance of investment account(s) and not- originating from unrealized profit and loss account(s) are assumed to+ Any transactions affecting balance of investment account(s) and not+ originating from unrealized profit and loss account(s) are assumed to be your investments or withdrawals. - At a minimum, you need to supply a query (which could be just an ac-+ At a minimum, you need to supply a query (which could be just an ac- count name) to select your investments with --inv, and another query to identify your profit and loss transactions with --pnl. - It will compute and display the internalized rate of return (IRR) and- time-weighted rate of return (TWR) for your investments for the time- period requested. Both rates of return are annualized before display,+ It will compute and display the internalized rate of return (IRR) and+ time-weighted rate of return (TWR) for your investments for the time+ period requested. Both rates of return are annualized before display, regardless of the length of reporting interval. stats stats Show some journal statistics. - 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. Example:@@ -2594,14 +2595,14 @@ Commodities : 1 ($) Market prices : 12 ($) - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. tags tags- List all the tag names used in the journal. With a TAGREGEX argument,- only tag names matching the regular expression (case insensitive) are- shown. With QUERY arguments, only transactions matching the query are+ List all the tag names used in the journal. With a TAGREGEX argument,+ only tag names matching the regular expression (case insensitive) are+ shown. With QUERY arguments, only transactions matching the query are considered. With --values flag, the tags' unique values are listed in- stead. @@ -2609,13 +2610,13 @@ test Run built-in unit tests. - This command runs the unit tests built in to hledger and hledger-lib,- printing the results on stdout. If any test fails, the exit code will+ This command runs the unit tests built in to hledger and hledger-lib,+ printing the results on stdout. If any test fails, the exit code will be non-zero. - This is mainly used by hledger developers, but you can also use it to- sanity-check the installed hledger executable on your platform. All- tests are expected to pass - if you ever see a failure, please report+ This is mainly used by hledger developers, but you can also use it to+ sanity-check the installed hledger executable on your platform. All+ tests are expected to pass - if you ever see a failure, please report as a bug! This command also accepts tasty test runner options, written after a --@@ -2624,32 +2625,32 @@ $ hledger test -- -pData.Amount --color=never - For help on these, see https://github.com/feuerbach/tasty#options (--+ For help on these, see https://github.com/feuerbach/tasty#options (-- --help currently doesn't show them). 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+ 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: 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:@@ -2664,7 +2665,7 @@ 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@@ -2684,14 +2685,14 @@ count, but it's superseded now by the built-in roi command. Experimental add-ons- These are available in source form in the hledger repo's bin/ direc-- tory. They may be less mature and documented than built-in commands.+ These are available in source form in the hledger repo's bin/ direc-+ tory. They may be less mature and documented 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. chart@@ -2701,21 +2702,21 @@ hledger-check.hs checks more powerful account balance assertions. 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). LIMITATIONS- 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@@ -2731,33 +2732,33 @@ 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 re-- member 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 re-+ member 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@@ -2776,7 +2777,7 @@ $ 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@@ -2797,7 +2798,7 @@ 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) @@ -2811,7 +2812,7 @@ 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) @@ -2819,4 +2820,4 @@ -hledger 1.16.1 December 2019 hledger(1)+hledger 1.16.2 January 2020 hledger(1)
embeddedfiles/hledger_csv.5 view
@@ -1,6 +1,6 @@ .\"t -.TH "hledger_csv" "5" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger_csv" "5" "January 2020" "hledger 1.16.2" "hledger User Manuals" @@ -508,6 +508,7 @@ .PP \f[C]balanceN\f[R] sets a balance assertion amount (or if the posting amount is left empty, a balance assignment).+You may need to adjust this with the \f[C]balance-type\f[R] rule. .PP Finally, \f[C]commentN\f[R] sets a comment on the Nth posting. Comments can also contain tags, as usual.@@ -731,6 +732,34 @@ ## common rules include categorisation.rules+\f[R]+.fi+.SS \f[C]balance-type\f[R]+.PP+Balance assertions generated by assigning to balanceN are of the simple+\f[C]=\f[R] type by default, which is a single-commodity,+subaccount-excluding assertion.+You may find the subaccount-including variants more useful, eg if you+have created some virtual subaccounts of checking to help with+budgeting.+You can select a different type of assertion with the+\f[C]balance-type\f[R] rule:+.IP+.nf+\f[C]+# balance assertions will consider all commodities and all subaccounts+balance-type ==*+\f[R]+.fi+.PP+Here are the balance assertion types for quick reference:+.IP+.nf+\f[C]+= single commodity, exclude subaccounts+=* single commodity, include subaccounts+== multi commodity, exclude subaccounts+==* multi commodity, include subaccounts \f[R] .fi .SH TIPS
embeddedfiles/hledger_csv.info view
@@ -1,9 +1,9 @@-This is hledger_csv.info, produced by makeinfo version 6.5 from stdin.+This is hledger_csv.info, produced by makeinfo version 6.7 from stdin. File: hledger_csv.info, Node: Top, Next: EXAMPLES, Up: (dir) -hledger_csv(5) hledger 1.16.1+hledger_csv(5) hledger 1.16.2 ***************************** hledger can read CSV (comma-separated value, or character-separated@@ -376,6 +376,7 @@ * date-format:: * newest-first:: * include::+* balance-type:: File: hledger_csv.info, Node: skip, Next: fields, Up: CSV RULES@@ -466,7 +467,8 @@ affects ALL postings. 'balanceN' sets a balance assertion amount (or if the posting amount-is left empty, a balance assignment).+is left empty, a balance assignment). You may need to adjust this with+the 'balance-type' rule. Finally, 'commentN' sets a comment on the Nth posting. Comments can also contain tags, as usual.@@ -625,7 +627,7 @@ newest-first -File: hledger_csv.info, Node: include, Prev: newest-first, Up: CSV RULES+File: hledger_csv.info, Node: include, Next: balance-type, Prev: newest-first, Up: CSV RULES 2.8 'include' =============@@ -648,6 +650,29 @@ include categorisation.rules +File: hledger_csv.info, Node: balance-type, Prev: include, Up: CSV RULES++2.9 'balance-type'+==================++Balance assertions generated by assigning to balanceN are of the simple+'=' type by default, which is a single-commodity, subaccount-excluding+assertion. You may find the subaccount-including variants more useful,+eg if you have created some virtual subaccounts of checking to help with+budgeting. You can select a different type of assertion with the+'balance-type' rule:++# balance assertions will consider all commodities and all subaccounts+balance-type ==*++ Here are the balance assertion types for quick reference:++= single commodity, exclude subaccounts+=* single commodity, include subaccounts+== multi commodity, exclude subaccounts+==* multi commodity, include subaccounts++ File: hledger_csv.info, Node: TIPS, Prev: CSV RULES, Up: Top 3 TIPS@@ -900,45 +925,52 @@ Ref: #paypal6532 Node: CSV RULES14415 Ref: #csv-rules14524-Node: skip14769-Ref: #skip14862-Node: fields15237-Ref: #fields15359-Node: Transaction field names16426-Ref: #transaction-field-names16586-Node: Posting field names16697-Ref: #posting-field-names16849-Node: field assignment18081-Ref: #field-assignment18217-Node: if19035-Ref: #if19144-Node: end20860-Ref: #end20966-Node: date-format21190-Ref: #date-format21322-Node: newest-first22071-Ref: #newest-first22209-Node: include22892-Ref: #include23000-Node: TIPS23444-Ref: #tips23526-Node: Valid CSV23775-Ref: #valid-csv23894-Node: Other separator characters24086-Ref: #other-separator-characters24274-Node: Reading multiple CSV files24603-Ref: #reading-multiple-csv-files24800-Node: Valid transactions25041-Ref: #valid-transactions25219-Node: Deduplicating importing25847-Ref: #deduplicating-importing26026-Node: Setting amounts27059-Ref: #setting-amounts27228-Node: Setting currency/commodity28214-Ref: #setting-currencycommodity28406-Node: Referencing other fields29209-Ref: #referencing-other-fields29409-Node: How CSV rules are evaluated30306-Ref: #how-csv-rules-are-evaluated30477+Node: skip14786+Ref: #skip14879+Node: fields15254+Ref: #fields15376+Node: Transaction field names16443+Ref: #transaction-field-names16603+Node: Posting field names16714+Ref: #posting-field-names16866+Node: field assignment18157+Ref: #field-assignment18293+Node: if19111+Ref: #if19220+Node: end20936+Ref: #end21042+Node: date-format21266+Ref: #date-format21398+Node: newest-first22147+Ref: #newest-first22285+Node: include22968+Ref: #include23097+Node: balance-type23541+Ref: #balance-type23659+Node: TIPS24359+Ref: #tips24441+Node: Valid CSV24690+Ref: #valid-csv24809+Node: Other separator characters25001+Ref: #other-separator-characters25189+Node: Reading multiple CSV files25518+Ref: #reading-multiple-csv-files25715+Node: Valid transactions25956+Ref: #valid-transactions26134+Node: Deduplicating importing26762+Ref: #deduplicating-importing26941+Node: Setting amounts27974+Ref: #setting-amounts28143+Node: Setting currency/commodity29129+Ref: #setting-currencycommodity29321+Node: Referencing other fields30124+Ref: #referencing-other-fields30324+Node: How CSV rules are evaluated31221+Ref: #how-csv-rules-are-evaluated31392 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger_csv.txt view
@@ -396,7 +396,8 @@ fects ALL postings. balanceN sets a balance assertion amount (or if the posting amount is- left empty, a balance assignment).+ left empty, a balance assignment). You may need to adjust this with+ the balance-type rule. Finally, commentN sets a comment on the Nth posting. Comments can also contain tags, as usual.@@ -406,11 +407,11 @@ field assignment HLEDGERFIELDNAME FIELDVALUE - Instead of or in addition to a fields list, you can use a "field as-- signment" rule to set the value of a single hledger field, by writing- its name (any of the standard hledger field names above) followed by a- text value. The value may contain interpolated CSV fields, referenced- by their 1-based position in the CSV record (%N), or by the name they+ Instead of or in addition to a fields list, you can use a "field as-+ signment" rule to set the value of a single hledger field, by writing+ its name (any of the standard hledger field names above) followed by a+ text value. The value may contain interpolated CSV fields, referenced+ by their 1-based position in the CSV record (%N), or by the name they were given in the fields list (%CSVFIELDNAME). Some examples: # set the amount to the 4th CSV field, with " USD" appended@@ -419,7 +420,7 @@ # combine three fields to make a comment, containing note: and date: tags comment note: %somefield - %anotherfield, date: %1 - Interpolation strips outer whitespace (so a CSV value like " 1 " be-+ Interpolation strips outer whitespace (so a CSV value like " 1 " be- comes 1 when interpolated) (#1051). See TIPS below for more about ref- erencing other fields. @@ -434,28 +435,28 @@ RULE RULE - Conditional blocks ("if blocks") are a block of rules that are applied- only to CSV records which match certain patterns. They are often used+ Conditional blocks ("if blocks") are a block of rules that are applied+ only to CSV records which match certain patterns. They are often used for customising account names based on transaction descriptions. A single pattern can be written on the same line as the "if"; or multi- ple patterns can be written on the following lines, non-indented. Mul-- tiple patterns are OR'd (any one of them can match). Patterns are+ tiple patterns are OR'd (any one of them can match). Patterns are case-insensitive regular expressions which try to match anywhere within- the whole CSV record (POSIX extended regular expressions with some ad-+ the whole CSV record (POSIX extended regular expressions with some ad- ditions, see https://hledger.org/hledger.html#regular-expressions). Note the CSV record they see is close to, but not identical to, the one in the CSV file; enclosing double quotes will be removed, and the sepa- rator character is always comma. - It's not yet easy to match within a specific field. If the data does+ It's not yet easy to match within a specific field. If the data does not contain commas, you can hack it with a regular expression like: # match "foo" in the fourth field if ^([^,]*,){3}foo - After the patterns there should be one or more rules to apply, all in-- dented by at least one space. Three kinds of rule are allowed in con-+ After the patterns there should be one or more rules to apply, all in-+ dented by at least one space. Three kinds of rule are allowed in con- ditional blocks: o field assignments (to set a hledger field)@@ -479,7 +480,7 @@ comment XXX deductible ? check it end- This rule can be used inside if blocks (only), to make hledger stop+ This rule can be used inside if blocks (only), to make hledger stop reading this CSV file and move on to the next input file, or to command execution. Eg: @@ -490,10 +491,10 @@ date-format date-format DATEFMT - This is a helper for the date (and date2) fields. If your CSV dates- are not formatted like YYYY-MM-DD, YYYY/MM/DD or YYYY.MM.DD, you'll- need to add a date-format rule describing them with a strptime date- parsing pattern, which must parse the CSV date value completely. Some+ This is a helper for the date (and date2) fields. If your CSV dates+ are not formatted like YYYY-MM-DD, YYYY/MM/DD or YYYY.MM.DD, you'll+ need to add a date-format rule describing them with a strptime date+ parsing pattern, which must parse the CSV date value completely. Some examples: # MM/DD/YY@@ -515,15 +516,15 @@ mat.html#v:formatTime newest-first- hledger always sorts the generated transactions by date. Transactions- on the same date should appear in the same order as their CSV records,- as hledger can usually auto-detect whether the CSV's normal order is+ hledger always sorts the generated transactions by date. Transactions+ on the same date should appear in the same order as their CSV records,+ as hledger can usually auto-detect whether the CSV's normal order is oldest first or newest first. But if all of the following are true: - o the CSV might sometimes contain just one day of data (all records+ o the CSV might sometimes contain just one day of data (all records having the same date) - o the CSV records are normally in reverse chronological order (newest+ o the CSV records are normally in reverse chronological order (newest at the top) o and you care about preserving the order of same-day transactions@@ -536,9 +537,9 @@ include include RULESFILE - This includes the contents of another CSV rules file at this point.- RULESFILE is an absolute file path or a path relative to the current- file's directory. This can be useful for sharing common rules between+ This includes the contents of another CSV rules file at this point.+ RULESFILE is an absolute file path or a path relative to the current+ file's directory. This can be useful for sharing common rules between several rules files, eg: # someaccount.csv.rules@@ -551,6 +552,24 @@ ## common rules include categorisation.rules + balance-type+ Balance assertions generated by assigning to balanceN are of the simple+ = type by default, which is a single-commodity, subaccount-excluding+ assertion. You may find the subaccount-including variants more useful,+ eg if you have created some virtual subaccounts of checking to help+ with budgeting. You can select a different type of assertion with the+ balance-type rule:++ # balance assertions will consider all commodities and all subaccounts+ balance-type ==*++ Here are the balance assertion types for quick reference:++ = single commodity, exclude subaccounts+ =* single commodity, include subaccounts+ == multi commodity, exclude subaccounts+ ==* multi commodity, include subaccounts+ TIPS Valid CSV hledger accepts CSV conforming to RFC 4180. When CSV values are en-@@ -760,4 +779,4 @@ -hledger 1.16.1 December 2019 hledger_csv(5)+hledger 1.16.2 January 2020 hledger_csv(5)
embeddedfiles/hledger_journal.5 view
@@ -1,6 +1,6 @@ .\"t -.TH "hledger_journal" "5" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger_journal" "5" "January 2020" "hledger 1.16.2" "hledger User Manuals"
embeddedfiles/hledger_journal.info view
@@ -1,10 +1,10 @@-This is hledger_journal.info, produced by makeinfo version 6.5 from+This is hledger_journal.info, produced by makeinfo version 6.7 from stdin. File: hledger_journal.info, Node: Top, Next: FILE FORMAT, Up: (dir) -hledger_journal(5) hledger 1.16.1+hledger_journal(5) hledger 1.16.2 ********************************* hledger's usual data source is a plain text file containing journal@@ -1863,3 +1863,8 @@ Ref: #editor-support63334 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger_journal.txt view
@@ -1414,4 +1414,4 @@ -hledger 1.16.1 December 2019 hledger_journal(5)+hledger 1.16.2 January 2020 hledger_journal(5)
embeddedfiles/hledger_timeclock.5 view
@@ -1,5 +1,5 @@ -.TH "hledger_timeclock" "5" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger_timeclock" "5" "January 2020" "hledger 1.16.2" "hledger User Manuals" @@ -63,7 +63,7 @@ and perhaps the extras in ledgerutils.el .IP \[bu] 2 at the command line, use these bash aliases:-\f[C]shell alias ti=\[dq]echo i \[ga]date \[aq]+%Y-%m-%d %H:%M:%S\[aq]\[ga] \[rs]$* >>$TIMELOG\[dq] alias to=\[dq]echo o \[ga]date \[aq]+%Y-%m-%d %H:%M:%S\[aq]\[ga] >>$TIMELOG\[dq]\f[R]+\f[C]shell alias ti=\[dq]echo i \[ga]date \[aq]+%Y-%m-%d %H:%M:%S\[aq]\[ga] \[rs]$* >>$TIMELOG\[dq] alias to=\[dq]echo o \[ga]date \[aq]+%Y-%m-%d %H:%M:%S\[aq]\[ga] >>$TIMELOG\[dq]\f[R] .IP \[bu] 2 or use the old \f[C]ti\f[R] and \f[C]to\f[R] scripts in the ledger 2.x repository.
embeddedfiles/hledger_timeclock.info view
@@ -1,10 +1,10 @@-This is hledger_timeclock.info, produced by makeinfo version 6.5 from+This is hledger_timeclock.info, produced by makeinfo version 6.7 from stdin. File: hledger_timeclock.info, Node: Top, Up: (dir) -hledger_timeclock(5) hledger 1.16.1+hledger_timeclock(5) hledger 1.16.2 *********************************** hledger can read timeclock files. As with Ledger, these are (a subset@@ -59,3 +59,8 @@ Node: Top78 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger_timeclock.txt view
@@ -45,9 +45,9 @@ o use emacs and the built-in timeclock.el, or the extended timeclock- x.el and perhaps the extras in ledgerutils.el - o at the command line, use these bash aliases: shell alias ti="echo i- `date '+%Y-%m-%d %H:%M:%S'` \$* >>$TIMELOG" alias to="echo o `date- '+%Y-%m-%d %H:%M:%S'` >>$TIMELOG"+ o at the command line, use these bash aliases: shell alias ti="echo+ i `date '+%Y-%m-%d %H:%M:%S'` \$* >>$TIMELOG" alias to="echo o+ `date '+%Y-%m-%d %H:%M:%S'` >>$TIMELOG" o or use the old ti and to scripts in the ledger 2.x repository. These rely on a "timeclock" executable which I think is just the ledger 2@@ -78,4 +78,4 @@ -hledger 1.16.1 December 2019 hledger_timeclock(5)+hledger 1.16.2 January 2020 hledger_timeclock(5)
embeddedfiles/hledger_timedot.5 view
@@ -1,5 +1,5 @@ -.TH "hledger_timedot" "5" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger_timedot" "5" "January 2020" "hledger 1.16.2" "hledger User Manuals"
embeddedfiles/hledger_timedot.info view
@@ -1,10 +1,10 @@-This is hledger_timedot.info, produced by makeinfo version 6.5 from+This is hledger_timedot.info, produced by makeinfo version 6.7 from stdin. File: hledger_timedot.info, Node: Top, Next: FILE FORMAT, Up: (dir) -hledger_timedot(5) hledger 1.16.1+hledger_timedot(5) hledger 1.16.2 ********************************* Timedot is a plain text format for logging dated, categorised quantities@@ -115,3 +115,8 @@ Ref: #file-format913 End Tag Table+++Local Variables:+coding: utf-8+End:
embeddedfiles/hledger_timedot.txt view
@@ -124,4 +124,4 @@ -hledger 1.16.1 December 2019 hledger_timedot(5)+hledger 1.16.2 January 2020 hledger_timedot(5)
hledger.1 view
@@ -1,6 +1,6 @@ .\"t -.TH "hledger" "1" "December 2019" "hledger 1.16.1" "hledger User Manuals"+.TH "hledger" "1" "January 2020" "hledger 1.16.2" "hledger User Manuals" @@ -159,101 +159,101 @@ .PP General help options: .TP-.B \f[C]-h --help\f[R]+\f[B]\f[CB]-h --help\f[B]\f[R] show general usage (or after COMMAND, command usage) .TP-.B \f[C]--version\f[R]+\f[B]\f[CB]--version\f[B]\f[R] show version .TP-.B \f[C]--debug[=N]\f[R]+\f[B]\f[CB]--debug[=N]\f[B]\f[R] show debug output (levels 1-9, default: 1) .PP General input options: .TP-.B \f[C]-f FILE --file=FILE\f[R]+\f[B]\f[CB]-f FILE --file=FILE\f[B]\f[R] use a different input file. For stdin, use - (default: \f[C]$LEDGER_FILE\f[R] or \f[C]$HOME/.hledger.journal\f[R]) .TP-.B \f[C]--rules-file=RULESFILE\f[R]+\f[B]\f[CB]--rules-file=RULESFILE\f[B]\f[R] Conversion rules file to use when reading CSV (default: FILE.rules) .TP-.B \f[C]--separator=CHAR\f[R]+\f[B]\f[CB]--separator=CHAR\f[B]\f[R] Field separator to expect when reading CSV (default: \[aq],\[aq]) .TP-.B \f[C]--alias=OLD=NEW\f[R]+\f[B]\f[CB]--alias=OLD=NEW\f[B]\f[R] rename accounts named OLD to NEW .TP-.B \f[C]--anon\f[R]+\f[B]\f[CB]--anon\f[B]\f[R] anonymize accounts and payees .TP-.B \f[C]--pivot FIELDNAME\f[R]+\f[B]\f[CB]--pivot FIELDNAME\f[B]\f[R] use some other field or tag for the account name .TP-.B \f[C]-I --ignore-assertions\f[R]+\f[B]\f[CB]-I --ignore-assertions\f[B]\f[R] ignore any failing balance assertions .PP General reporting options: .TP-.B \f[C]-b --begin=DATE\f[R]+\f[B]\f[CB]-b --begin=DATE\f[B]\f[R] include postings/txns on or after this date .TP-.B \f[C]-e --end=DATE\f[R]+\f[B]\f[CB]-e --end=DATE\f[B]\f[R] include postings/txns before this date .TP-.B \f[C]-D --daily\f[R]+\f[B]\f[CB]-D --daily\f[B]\f[R] multiperiod/multicolumn report by day .TP-.B \f[C]-W --weekly\f[R]+\f[B]\f[CB]-W --weekly\f[B]\f[R] multiperiod/multicolumn report by week .TP-.B \f[C]-M --monthly\f[R]+\f[B]\f[CB]-M --monthly\f[B]\f[R] multiperiod/multicolumn report by month .TP-.B \f[C]-Q --quarterly\f[R]+\f[B]\f[CB]-Q --quarterly\f[B]\f[R] multiperiod/multicolumn report by quarter .TP-.B \f[C]-Y --yearly\f[R]+\f[B]\f[CB]-Y --yearly\f[B]\f[R] multiperiod/multicolumn report by year .TP-.B \f[C]-p --period=PERIODEXP\f[R]+\f[B]\f[CB]-p --period=PERIODEXP\f[B]\f[R] set start date, end date, and/or reporting interval all at once using period expressions syntax .TP-.B \f[C]--date2\f[R]+\f[B]\f[CB]--date2\f[B]\f[R] match the secondary date instead (see command help for other effects) .TP-.B \f[C]-U --unmarked\f[R]+\f[B]\f[CB]-U --unmarked\f[B]\f[R] include only unmarked postings/txns (can combine with -P or -C) .TP-.B \f[C]-P --pending\f[R]+\f[B]\f[CB]-P --pending\f[B]\f[R] include only pending postings/txns .TP-.B \f[C]-C --cleared\f[R]+\f[B]\f[CB]-C --cleared\f[B]\f[R] include only cleared postings/txns .TP-.B \f[C]-R --real\f[R]+\f[B]\f[CB]-R --real\f[B]\f[R] include only non-virtual postings .TP-.B \f[C]-NUM --depth=NUM\f[R]+\f[B]\f[CB]-NUM --depth=NUM\f[B]\f[R] hide/aggregate accounts or postings more than NUM levels deep .TP-.B \f[C]-E --empty\f[R]+\f[B]\f[CB]-E --empty\f[B]\f[R] show items with zero amount, normally hidden (and vice-versa in hledger-ui/hledger-web) .TP-.B \f[C]-B --cost\f[R]+\f[B]\f[CB]-B --cost\f[B]\f[R] convert amounts to their cost at transaction time (using the transaction price, if any) .TP-.B \f[C]-V --value\f[R]+\f[B]\f[CB]-V --value\f[B]\f[R] convert amounts to their market value on the report end date (using the most recent applicable market price, if any) .TP-.B \f[C]--auto\f[R]+\f[B]\f[CB]--auto\f[B]\f[R] apply automated posting rules to modify transactions. .TP-.B \f[C]--forecast\f[R]+\f[B]\f[CB]--forecast\f[B]\f[R] apply periodic transaction rules to generate future transactions, to 6 months from now or report end date. .PP@@ -773,7 +773,7 @@ .PP .TS tab(@);-l l.+l r. T{ \f[C]-p \[dq]2009\[dq]\f[R] T}@T{@@ -1101,20 +1101,20 @@ The TYPE part basically selects either \[dq]cost\[dq], or \[dq]market value\[dq] plus a valuation date: .TP-.B \f[C]--value=cost\f[R]+\f[B]\f[CB]--value=cost\f[B]\f[R] Convert amounts to cost, using the prices recorded in transactions. .TP-.B \f[C]--value=end\f[R]+\f[B]\f[CB]--value=end\f[B]\f[R] Convert amounts to their value in a default valuation commodity, using market prices on the last day of the report period (or if unspecified, the journal\[aq]s end date); or in multiperiod reports, market prices on the last day of each subperiod. .TP-.B \f[C]--value=now\f[R]+\f[B]\f[CB]--value=now\f[B]\f[R] Convert amounts to their value in default valuation commodity using current market prices (as of when report is generated). .TP-.B \f[C]--value=YYYY-MM-DD\f[R]+\f[B]\f[CB]--value=YYYY-MM-DD\f[B]\f[R] Convert amounts to their value in default valuation commodity using market prices on this date. .PP@@ -1509,30 +1509,30 @@ .PP \f[B]Additional notes\f[R] .TP-.B \f[I]cost\f[R]+\f[I]cost\f[R] calculated using price(s) recorded in the transaction(s). .TP-.B \f[I]value\f[R]+\f[I]value\f[R] market value using available market price declarations, or the unchanged amount if no conversion rate can be found. .TP-.B \f[I]report start\f[R]+\f[I]report start\f[R] the first day of the report period specified with -b or -p or date:, otherwise today. .TP-.B \f[I]report or journal start\f[R]+\f[I]report or journal start\f[R] the first day of the report period specified with -b or -p or date:, otherwise the earliest transaction date in the journal, otherwise today. .TP-.B \f[I]report end\f[R]+\f[I]report end\f[R] the last day of the report period specified with -e or -p or date:, otherwise today. .TP-.B \f[I]report or journal end\f[R]+\f[I]report or journal end\f[R] the last day of the report period specified with -e or -p or date:, otherwise the latest transaction date in the journal, otherwise today. .TP-.B \f[I]report interval\f[R]+\f[I]report interval\f[R] a flag (-D/-W/-M/-Q/-Y) or period expression that activates the report\[aq]s multi-period mode (whether showing one or many subperiods). .SS Combining -B, -V, -X, --value@@ -1646,12 +1646,12 @@ Remember these can also be prefixed with \f[B]\f[CB]not:\f[B]\f[R], eg to exclude a particular subaccount. .TP-.B \f[B]\f[CB]REGEX\f[B], \f[CB]acct:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]REGEX\f[R]\f[B], \f[R]\f[C]acct:REGEX\f[R]\f[B]\f[R] match account names by this regular expression. (With no prefix, \f[C]acct:\f[R] is assumed.) same as above .TP-.B \f[B]\f[CB]amt:N, amt:<N, amt:<=N, amt:>N, amt:>=N\f[B]\f[R]+\f[B]\f[R]\f[C]amt:N, amt:<N, amt:<=N, amt:>N, amt:>=N\f[R]\f[B]\f[R] match postings with a single-commodity amount that is equal to, less than, or greater than N. (Multi-commodity amounts are not tested, and will always match.) The@@ -1659,10 +1659,10 @@ the two signed numbers are compared. Otherwise, the absolute magnitudes are compared, ignoring sign. .TP-.B \f[B]\f[CB]code:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]code:REGEX\f[R]\f[B]\f[R] match by transaction code (eg check number) .TP-.B \f[B]\f[CB]cur:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]cur:REGEX\f[R]\f[B]\f[R] match postings or transactions including any amounts whose currency/commodity symbol is fully matched by REGEX. (For a partial match, use \f[C].*REGEX.*\f[R]).@@ -1673,10 +1673,10 @@ \f[C]hledger print cur:\[aq]\[rs]$\[aq]\f[R] or \f[C]hledger print cur:\[rs]\[rs]$\f[R]. .TP-.B \f[B]\f[CB]desc:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]desc:REGEX\f[R]\f[B]\f[R] match transaction descriptions. .TP-.B \f[B]\f[CB]date:PERIODEXPR\f[B]\f[R]+\f[B]\f[R]\f[C]date:PERIODEXPR\f[R]\f[B]\f[R] match dates within the specified period. PERIODEXPR is a period expression (with no report interval). Examples: \f[C]date:2016\f[R], \f[C]date:thismonth\f[R],@@ -1684,27 +1684,27 @@ If the \f[C]--date2\f[R] command line flag is present, this matches secondary dates instead. .TP-.B \f[B]\f[CB]date2:PERIODEXPR\f[B]\f[R]+\f[B]\f[R]\f[C]date2:PERIODEXPR\f[R]\f[B]\f[R] match secondary dates within the specified period. .TP-.B \f[B]\f[CB]depth:N\f[B]\f[R]+\f[B]\f[R]\f[C]depth:N\f[R]\f[B]\f[R] match (or display, depending on command) accounts at or above this depth .TP-.B \f[B]\f[CB]note:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]note:REGEX\f[R]\f[B]\f[R] match transaction notes (part of description right of \f[C]|\f[R], or whole description when there\[aq]s no \f[C]|\f[R]) .TP-.B \f[B]\f[CB]payee:REGEX\f[B]\f[R]+\f[B]\f[R]\f[C]payee:REGEX\f[R]\f[B]\f[R] match transaction payee/payer names (part of description left of \f[C]|\f[R], or whole description when there\[aq]s no \f[C]|\f[R]) .TP-.B \f[B]\f[CB]real:, real:0\f[B]\f[R]+\f[B]\f[R]\f[C]real:, real:0\f[R]\f[B]\f[R] match real or virtual postings respectively .TP-.B \f[B]\f[CB]status:, status:!, status:*\f[B]\f[R]+\f[B]\f[R]\f[C]status:, status:!, status:*\f[R]\f[B]\f[R] match unmarked, pending, or cleared transactions respectively .TP-.B \f[B]\f[CB]tag:REGEX[=REGEX]\f[B]\f[R]+\f[B]\f[R]\f[C]tag:REGEX[=REGEX]\f[R]\f[B]\f[R] match by tag name, and optionally also by tag value. Note a tag: query is considered to match a transaction if it matches any of the postings.@@ -1714,7 +1714,7 @@ The following special search term is used automatically in hledger-web, only: .TP-.B \f[B]\f[CB]inacct:ACCTNAME\f[B]\f[R]+\f[B]\f[R]\f[C]inacct:ACCTNAME\f[R]\f[B]\f[R] tells hledger-web to show the transaction register for this account. Can be filtered further with \f[C]acct\f[R] etc. .PP@@ -2669,9 +2669,9 @@ end of a period. .PP The closing transaction transfers balances to \[dq]equity:closing-balances\[dq].-The opening transaction transfers balances from \[dq]equity:opening-balances\[dq].+balances\[dq], and the opening transaction transfers balances from+\[dq]equity:opening balances\[dq], or you can customise these with the+\f[C]--close-to\f[R] and \f[C]--open-from\f[R] options. You can choose to print just one of the transactions by using the \f[C]--opening\f[R] or \f[C]--closing\f[R] flag. .PP
hledger.cabal view
@@ -4,10 +4,10 @@ -- -- see: https://github.com/sol/hpack ----- hash: 029bcf223345b932dacaaf3200f66a8d7529e1fad4bfe8343228720893aa27bb+-- hash: cc539eef932d55b9d6b5b80a453b650d5287c5b11de661043c97a855fd93a7ed name: hledger-version: 1.16.1+version: 1.16.2 synopsis: Command-line interface for the hledger accounting tool description: This is hledger's command-line interface. Its basic function is to read a plain text file describing@@ -144,7 +144,7 @@ other-modules: Paths_hledger ghc-options: -Wall -fno-warn-unused-do-bind -fno-warn-name-shadowing -fno-warn-missing-signatures -fno-warn-type-defaults -fno-warn-orphans -optP-Wno-nonportable-include-path- cpp-options: -DVERSION="1.16.1"+ cpp-options: -DVERSION="1.16.2" build-depends: Decimal , Diff@@ -160,10 +160,10 @@ , filepath , hashable >=1.2.4 , haskeline >=0.6- , hledger-lib >=1.16.1 && <1.17+ , hledger-lib >=1.16.2 && <1.17 , lucid , math-functions >=0.2.0.0- , megaparsec >=7.0.0 && <8+ , megaparsec >=7.0.0 && <8.1 , mtl >=2.2.1 , old-time , parsec >=3@@ -196,7 +196,7 @@ hs-source-dirs: app ghc-options: -Wall -fno-warn-unused-do-bind -fno-warn-name-shadowing -fno-warn-missing-signatures -fno-warn-type-defaults -fno-warn-orphans -optP-Wno-nonportable-include-path- cpp-options: -DVERSION="1.16.1"+ cpp-options: -DVERSION="1.16.2" build-depends: Decimal , ansi-terminal >=0.6.2.3@@ -211,9 +211,9 @@ , filepath , haskeline >=0.6 , hledger- , hledger-lib >=1.16.1 && <1.17+ , hledger-lib >=1.16.2 && <1.17 , math-functions >=0.2.0.0- , megaparsec >=7.0.0 && <8+ , megaparsec >=7.0.0 && <8.1 , mtl >=2.2.1 , old-time , parsec >=3@@ -247,7 +247,7 @@ hs-source-dirs: test ghc-options: -Wall -fno-warn-unused-do-bind -fno-warn-name-shadowing -fno-warn-missing-signatures -fno-warn-type-defaults -fno-warn-orphans -optP-Wno-nonportable-include-path- cpp-options: -DVERSION="1.16.1"+ cpp-options: -DVERSION="1.16.2" build-depends: Decimal , ansi-terminal >=0.6.2.3@@ -262,9 +262,9 @@ , filepath , haskeline >=0.6 , hledger- , hledger-lib >=1.16.1 && <1.17+ , hledger-lib >=1.16.2 && <1.17 , math-functions >=0.2.0.0- , megaparsec >=7.0.0 && <8+ , megaparsec >=7.0.0 && <8.1 , mtl >=2.2.1 , old-time , parsec >=3@@ -311,10 +311,10 @@ , filepath , haskeline >=0.6 , hledger- , hledger-lib >=1.16.1 && <1.17+ , hledger-lib >=1.16.2 && <1.17 , html , math-functions >=0.2.0.0- , megaparsec >=7.0.0 && <8+ , megaparsec >=7.0.0 && <8.1 , mtl >=2.2.1 , old-time , parsec >=3
hledger.info view
@@ -1,9 +1,9 @@-This is hledger.info, produced by makeinfo version 6.5 from stdin.+This is hledger.info, produced by makeinfo version 6.7 from stdin. File: hledger.info, Node: Top, Next: EXAMPLES, Up: (dir) -hledger(1) hledger 1.16.1+hledger(1) hledger 1.16.2 ************************* This is hledger's command-line interface (there are also terminal and@@ -2187,9 +2187,10 @@ end of a period. The closing transaction transfers balances to "equity:closing-balances". The opening transaction transfers balances from-"equity:opening balances". You can choose to print just one of the-transactions by using the '--opening' or '--closing' flag.+balances", and the opening transaction transfers balances from+"equity:opening balances", or you can customise these with the+'--close-to' and '--open-from' options. You can choose to print just+one of the transactions by using the '--opening' or '--closing' flag. If you split your journal files by time (eg yearly), you will typically run this command at the end of the year, and save the closing@@ -3290,78 +3291,83 @@ Ref: #check-dupes75909 Node: close76202 Ref: #close76316-Node: commodities79903-Ref: #commodities80030-Node: descriptions80112-Ref: #descriptions80240-Node: diff80421-Ref: #diff80527-Node: files81574-Ref: #files81674-Node: help81821-Ref: #help81921-Node: import83002-Ref: #import83116-Node: Importing balance assignments84009-Ref: #importing-balance-assignments84157-Node: incomestatement84806-Ref: #incomestatement84939-Node: notes86343-Ref: #notes86456-Node: payees86582-Ref: #payees86688-Node: prices86846-Ref: #prices86952-Node: print87293-Ref: #print87403-Node: print-unique91896-Ref: #print-unique92022-Node: register92307-Ref: #register92434-Node: Custom register output96606-Ref: #custom-register-output96735-Node: register-match97997-Ref: #register-match98131-Node: rewrite98482-Ref: #rewrite98597-Node: Re-write rules in a file100452-Ref: #re-write-rules-in-a-file100586-Node: Diff output format101796-Ref: #diff-output-format101965-Node: rewrite vs print --auto103057-Ref: #rewrite-vs.-print---auto103236-Node: roi103792-Ref: #roi103890-Node: stats104902-Ref: #stats105001-Node: tags105789-Ref: #tags105887-Node: test106181-Ref: #test106265-Node: ADD-ON COMMANDS107012-Ref: #add-on-commands107122-Node: Official add-ons108410-Ref: #official-add-ons108550-Node: ui108630-Ref: #ui108717-Node: web108771-Ref: #web108860-Node: Third party add-ons108906-Ref: #third-party-add-ons109081-Ref: #diff-1109240-Node: iadd109339-Ref: #iadd109449-Node: interest109531-Ref: #interest109652-Node: irr109747-Ref: #irr109845-Node: Experimental add-ons109976-Ref: #experimental-add-ons110128-Node: autosync110376-Ref: #autosync110487-Node: chart110726-Ref: #chart110845-Node: check110916-Ref: #check111018+Node: commodities79982+Ref: #commodities80109+Node: descriptions80191+Ref: #descriptions80319+Node: diff80500+Ref: #diff80606+Node: files81653+Ref: #files81753+Node: help81900+Ref: #help82000+Node: import83081+Ref: #import83195+Node: Importing balance assignments84088+Ref: #importing-balance-assignments84236+Node: incomestatement84885+Ref: #incomestatement85018+Node: notes86422+Ref: #notes86535+Node: payees86661+Ref: #payees86767+Node: prices86925+Ref: #prices87031+Node: print87372+Ref: #print87482+Node: print-unique91975+Ref: #print-unique92101+Node: register92386+Ref: #register92513+Node: Custom register output96685+Ref: #custom-register-output96814+Node: register-match98076+Ref: #register-match98210+Node: rewrite98561+Ref: #rewrite98676+Node: Re-write rules in a file100531+Ref: #re-write-rules-in-a-file100665+Node: Diff output format101875+Ref: #diff-output-format102044+Node: rewrite vs print --auto103136+Ref: #rewrite-vs.-print---auto103315+Node: roi103871+Ref: #roi103969+Node: stats104981+Ref: #stats105080+Node: tags105868+Ref: #tags105966+Node: test106260+Ref: #test106344+Node: ADD-ON COMMANDS107091+Ref: #add-on-commands107201+Node: Official add-ons108489+Ref: #official-add-ons108629+Node: ui108709+Ref: #ui108796+Node: web108850+Ref: #web108939+Node: Third party add-ons108985+Ref: #third-party-add-ons109160+Ref: #diff-1109319+Node: iadd109418+Ref: #iadd109528+Node: interest109610+Ref: #interest109731+Node: irr109826+Ref: #irr109924+Node: Experimental add-ons110055+Ref: #experimental-add-ons110207+Node: autosync110455+Ref: #autosync110566+Node: chart110805+Ref: #chart110924+Node: check110995+Ref: #check111097 End Tag Table+++Local Variables:+coding: utf-8+End:
hledger.txt view
@@ -1926,50 +1926,51 @@ end of a period. The closing transaction transfers balances to "equity:closing bal-- ances". The opening transaction transfers balances from "equity:open-- ing balances". You can choose to print just one of the transactions by- using the --opening or --closing flag.+ ances", and the opening transaction transfers balances from "eq-+ uity:opening balances", or you can customise these with the --close-to+ and --open-from options. You can choose to print just one of the+ transactions by using the --opening or --closing flag. If you split your journal files by time (eg yearly), you will typically- run this command at the end of the year, and save the closing transac-- tion as last entry of the old file, and the opening transaction as the- first entry of the new file. This makes the files self contained, so- that correct balances are reported no matter which of them are loaded.- Ie, if you load just one file, the balances are initialised correctly;- or if you load several files, the redundant closing/opening transac-- tions cancel each other out. (They will show up in print or register- reports; you can exclude them with a query like not:desc:'(open-+ run this command at the end of the year, and save the closing transac-+ tion as last entry of the old file, and the opening transaction as the+ first entry of the new file. This makes the files self contained, so+ that correct balances are reported no matter which of them are loaded.+ Ie, if you load just one file, the balances are initialised correctly;+ or if you load several files, the redundant closing/opening transac-+ tions cancel each other out. (They will show up in print or register+ reports; you can exclude them with a query like not:desc:'(open- ing|closing) balances'.) If you're running a business, you might also use this command to "close- the books" at the end of an accounting period, transferring income- statement account balances to retained earnings. (You may want to+ the books" at the end of an accounting period, transferring income+ statement account balances to retained earnings. (You may want to change the equity account name to something like "equity:retained earn- ings".) - By default, the closing transaction is dated yesterday, the balances- are calculated as of end of yesterday, and the opening transaction is- dated today. To close on some other date, use: hledger close -e OPEN-- INGDATE. Eg, to close/open on the 2018/2019 boundary, use -e 2019.+ By default, the closing transaction is dated yesterday, the balances+ are calculated as of end of yesterday, and the opening transaction is+ dated today. To close on some other date, use: hledger close -e OPEN-+ INGDATE. Eg, to close/open on the 2018/2019 boundary, use -e 2019. You can also use -p or date:PERIOD (any starting date is ignored). - Both transactions will include balance assertions for the closed/re-+ Both transactions will include balance assertions for the closed/re- opened accounts. You probably shouldn't use status or realness filters- (like -C or -R or status:) with this command, or the generated balance- assertions will depend on these flags. Likewise, if you run this com-- mand with --auto, the balance assertions will probably always require+ (like -C or -R or status:) with this command, or the generated balance+ assertions will depend on these flags. Likewise, if you run this com-+ mand with --auto, the balance assertions will probably always require --auto. - When account balances have cost information (transaction prices), the- closing/opening transactions will preserve it, so that eg balance -B+ When account balances have cost information (transaction prices), the+ closing/opening transactions will preserve it, so that eg balance -B reports will not be affected. Examples: - Carrying asset/liability balances into a new file for 2019, all from+ Carrying asset/liability balances into a new file for 2019, all from command line: - Warning: we use >> here to append; be careful not to type a single >+ Warning: we use >> here to append; be careful not to type a single > which would wipe your journal! $ hledger close -f 2018.journal -e 2019 assets liabilities --opening >>2019.journal@@ -2018,18 +2019,18 @@ diff diff- Compares a particular account's transactions in two input files. It+ Compares a particular account's transactions in two input files. It shows any transactions to this account which are in one file but not in the other. More precisely, for each posting affecting this account in either file,- it looks for a corresponding posting in the other file which posts the- same amount to the same account (ignoring date, description, etc.)+ it looks for a corresponding posting in the other file which posts the+ same amount to the same account (ignoring date, description, etc.) Since postings not transactions are compared, this also works when mul- tiple bank transactions have been combined into a single journal entry. This is useful eg if you have downloaded an account's transactions from- your bank (eg as CSV data). When hledger and your bank disagree about+ your bank (eg as CSV data). When hledger and your bank disagree about the account balance, you can compare the bank data with your journal to find out the cause. @@ -2047,20 +2048,20 @@ files files- List all files included in the journal. With a REGEX argument, only+ List all files included in the journal. With a REGEX argument, only file names matching the regular expression (case sensitive) are shown. help help Show any of the hledger manuals. - The help command displays any of the main hledger manuals, in one of- several ways. Run it with no argument to list the manuals, or provide+ The help command displays any of the main hledger manuals, in one of+ several ways. Run it with no argument to list the manuals, or provide a full or partial manual name to select one. - hledger manuals are available in several formats. hledger help will- use the first of these display methods that it finds: info, man,- $PAGER, less, stdout (or when non-interactive, just stdout). You can+ hledger manuals are available in several formats. hledger help will+ use the first of these display methods that it finds: info, man,+ $PAGER, less, stdout (or when non-interactive, just stdout). You can force a particular viewer with the --info, --man, --pager, --cat flags. Examples:@@ -2087,9 +2088,9 @@ import import- Read new transactions added to each FILE since last run, and add them- to the main journal file. Or with --dry-run, just print the transac-- tions that would be added. Or with --catchup, just mark all of the+ Read new transactions added to each FILE since last run, and add them+ to the main journal file. Or with --dry-run, just print the transac-+ tions that would be added. Or with --catchup, just mark all of the FILEs' transactions as imported, without actually importing any. The input files are specified as arguments - no need to write -f before@@ -2100,36 +2101,36 @@ ing transactions are always added to the input files in increasing date order, and by saving .latest.FILE state files. - The --dry-run output is in journal format, so you can filter it, eg to+ The --dry-run output is in journal format, so you can filter it, eg to see only uncategorised transactions: $ hledger import --dry ... | hledger -f- print unknown --ignore-assertions Importing balance assignments- Entries added by import will have their posting amounts made explicit- (like hledger print -x). This means that any balance assignments in- imported files must be evaluated; but, imported files don't get to see- the main file's account balances. As a result, importing entries with+ Entries added by import will have their posting amounts made explicit+ (like hledger print -x). This means that any balance assignments in+ imported files must be evaluated; but, imported files don't get to see+ the main file's account balances. As a result, importing entries with balance assignments (eg from an institution that provides only balances- and not posting amounts) will probably generate incorrect posting+ and not posting amounts) will probably generate incorrect posting amounts. To avoid this problem, use print instead of import: $ hledger print IMPORTFILE [--new] >> $LEDGER_FILE - (If you think import should leave amounts implicit like print does,+ (If you think import should leave amounts implicit like print does, please test it and send a pull request.) incomestatement incomestatement, is- This command displays a simple income statement, showing revenues and- expenses during a period. It assumes that these accounts are under a- top-level revenue or income or expense account (case insensitive, plu-- ral forms also allowed). Note this report shows all account balances- with normal positive sign (like conventional financial statements, un-+ This command displays a simple income statement, showing revenues and+ expenses during a period. It assumes that these accounts are under a+ top-level revenue or income or expense account (case insensitive, plu-+ ral forms also allowed). Note this report shows all account balances+ with normal positive sign (like conventional financial statements, un- like balance/print/register) (experimental). - 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@@ -2154,12 +2155,12 @@ 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 mode with --change/--cumulative/--historical. Instead of abso-+ 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. Instead of abso- lute values percentages can be displayed with -%. - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. notes@@ -2187,10 +2188,10 @@ prices prices- Print market price directives from the journal. With --costs, also- print synthetic market prices based on transaction prices. With --in-- verted-costs, also print inverse prices based on transaction prices.- Prices (and postings providing prices) can be filtered by a query.+ Print market price directives from the journal. With --costs, also+ print synthetic market prices based on transaction prices. With --in-+ verted-costs, also print inverse prices based on transaction prices.+ Prices (and postings providing prices) can be filtered by a query. Price amounts are always displayed with their full precision. print@@ -2198,11 +2199,11 @@ Show transaction journal entries, sorted by date. The print command displays full journal entries (transactions) from the- journal file in date order, tidily formatted. With --date2, transac-+ journal file in date order, tidily formatted. With --date2, transac- tions are sorted by secondary date instead. print's output is always a valid hledger journal.- It preserves all transaction information, but it does not preserve di-+ It preserves all transaction information, but it does not preserve di- rectives or inter-transaction comments $ hledger print@@ -2228,39 +2229,39 @@ assets:bank:checking $-1 Normally, the journal entry's explicit or implicit amount style is pre-- served. Ie when an amount is omitted in the journal, it will be omit-- ted in the output. You can use the -x/--explicit flag to make all+ served. Ie when an amount is omitted in the journal, it will be omit-+ ted 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,- -x will cause postings with a multi-commodity amount (these can arise- when a multi-commodity transaction has an implicit amount) will be- split into multiple single-commodity postings, for valid journal out-+ -x will cause postings with a multi-commodity amount (these can arise+ when a multi-commodity transaction has an implicit amount) will be+ split into multiple single-commodity postings, for valid journal out- put. - With -B/--cost, amounts with transaction prices are converted to cost+ With -B/--cost, amounts with transaction prices are converted to cost using that price. This can be used for troubleshooting. - With -m/--match and a STR argument, print will show at most one trans-- action: the one one whose description is most similar to STR, and is- most recent. STR should contain at least two characters. If there is+ With -m/--match and a STR argument, print will show at most one trans-+ action: the one one whose description is most similar to STR, and is+ most recent. STR should contain at least two characters. If there is no similar-enough match, no transaction will be shown. With --new, for each FILE being read, hledger reads (and writes) a spe-- cial state file (.latest.FILE in the same directory), containing the- latest transaction date(s) that were seen last time FILE was read.- When this file is found, only transactions with newer dates (and new- transactions on the latest date) are printed. This is useful for ig-- noring already-seen entries in import data, such as downloaded CSV+ cial state file (.latest.FILE in the same directory), containing the+ latest transaction date(s) that were seen last time FILE was read.+ When this file is found, only transactions with newer dates (and new+ transactions on the latest date) are printed. This is useful for ig-+ noring already-seen entries in import data, such as downloaded CSV files. Eg: $ hledger -f bank1.csv print --new # shows transactions added since last print --new on this file - This assumes that transactions added to FILE always have same or in-- creasing dates, and that transactions on the same day do not get re-+ This assumes that transactions added to FILE always have same or in-+ creasing dates, and that transactions on the same day do not get re- ordered. See also the import command. - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. Here's an example of print's CSV output: $ hledger print -Ocsv@@ -2277,20 +2278,20 @@ "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.) print-unique@@ -2314,7 +2315,7 @@ Show postings and their running total. The register command displays postings in date order, one per line, and- their running total. This is typically used with a query selecting a+ their running total. This is typically used with a query selecting a particular account, to see that account's activity: $ hledger register checking@@ -2325,8 +2326,8 @@ With --date2, it shows and sorts by secondary date instead. - 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@@ -2336,18 +2337,18 @@ 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 ac-+ the whole report period). This flag implies --empty (see below). It+ is affected by --historical. It works best when showing just one ac- count 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. - The --invert flag negates all amounts. For example, it can be used on+ The --invert flag negates all amounts. For example, it can be used on an income account where amounts are normally displayed as negative num-- bers. It's also useful to show postings on the checking account to-+ bers. It's also useful to show postings on the checking account to- gether with the related account: $ hledger register --related --invert assets:checking@@ -2359,7 +2360,7 @@ 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@@ -2376,7 +2377,7 @@ 2008/11 0 $-2 2008/12 0 $-2 - Often, you'll want to see just one line per interval. The --depth op-+ Often, you'll want to see just one line per interval. The --depth op- tion helps with this, causing subaccounts to be aggregated: $ hledger register --monthly assets --depth 1h@@ -2384,17 +2385,17 @@ 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 in-- tervals. 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 in-+ tervals. 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+ The description and account columns normally share the space equally (about half of (width - 40) each). You can adjust this by adding a de- scription width as part of --width's argument, comma-separated: --width W,D . Here's a diagram (won't display correctly in --help):@@ -2412,27 +2413,27 @@ $ hledger reg -w 100,40 # set overall width 100, description width 40 $ hledger reg -w $COLUMNS,40 # use terminal width, & description width 40 - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. register-match register-match Print the one posting whose transaction description is closest to DESC,- in the style of the register command. If there are multiple equally- good matches, it shows the most recent. Query options (options, not- arguments) can be used to restrict the search space. Helps ledger-au-+ in the style of the register command. If there are multiple equally+ good matches, it shows the most recent. Query options (options, not+ arguments) can be used to restrict the search space. Helps ledger-au- tosync detect already-seen transactions when importing. rewrite rewrite Print all transactions, rewriting the postings of matched transactions.- For now the only rewrite available is adding new postings, like print+ For now the only rewrite available is adding new postings, like print --auto. This is a start at a generic rewriter of transaction entries. It reads- the default journal and prints the transactions, like print, but adds+ the default journal and prints the transactions, like print, but adds one or more specified postings to any transactions matching QUERY. The- posting amounts can be fixed, or a multiplier of the existing transac-+ posting amounts can be fixed, or a multiplier of the existing transac- tion's first posting amount. Examples:@@ -2448,7 +2449,7 @@ (reserve:grocery) *0.25 ; reserve 25% for grocery (reserve:) *0.25 ; reserve 25% for grocery - Note the single quotes to protect the dollar sign from bash, and the+ Note the single quotes to protect the dollar sign from bash, and the two spaces between account and amount. More:@@ -2458,16 +2459,16 @@ $ hledger rewrite -- expenses:gifts --add-posting '(budget:gifts) *-1"' $ hledger rewrite -- ^income --add-posting '(budget:foreign currency) *0.25 JPY; diversify' - Argument for --add-posting option is a usual posting of transaction- with an exception for amount specification. More precisely, you can+ Argument for --add-posting option is a usual posting of transaction+ with an exception for amount specification. More precisely, you can use '*' (star symbol) before the amount to indicate that that this is a- factor for an amount of original matched posting. If the amount in-+ factor for an amount of original matched posting. If the amount in- cludes a commodity name, the new posting amount will be in the new com-- modity; otherwise, it will be in the matched posting amount's commod-+ modity; otherwise, it will be in the matched posting amount's commod- ity. Re-write rules in a file- During the run this tool will execute so called "Automated Transac-+ During the run this tool will execute so called "Automated Transac- tions" found in any journal it process. I.e instead of specifying this operations in command line you can put them in a journal file. @@ -2482,7 +2483,7 @@ budget:gifts *-1 assets:budget *1 - Note that '=' (equality symbol) that is used instead of date in trans-+ Note that '=' (equality symbol) that is used instead of date in trans- actions you usually write. It indicates the query by which you want to match the posting to add new ones. @@ -2495,12 +2496,12 @@ --add-posting 'assets:budget *1' \ > rewritten-tidy-output.journal - It is important to understand that relative order of such entries in- journal is important. You can re-use result of previously added post-+ It is important to understand that relative order of such entries in+ journal is important. You can re-use result of previously added post- ings. Diff output format- To use this tool for batch modification of your journal files you may+ To use this tool for batch modification of your journal files you may find useful output in form of unified diff. $ hledger rewrite -- --diff -f examples/sample.journal '^income' --add-posting '(liabilities:tax) *.33'@@ -2524,10 +2525,10 @@ If you'll pass this through patch tool you'll get transactions contain- ing the posting that matches your query be updated. Note that multiple- files might be update according to list of input files specified via+ files might be update according to list of input files specified via --file options and include directives inside of these files. - Be careful. Whole transaction being re-formatted in a style of output+ Be careful. Whole transaction being re-formatted in a style of output from hledger print. See also:@@ -2535,48 +2536,48 @@ https://github.com/simonmichael/hledger/issues/99 rewrite vs. print --auto- This command predates print --auto, and currently does much the same+ This command predates print --auto, and currently does much the same thing, but with these differences: - o with multiple files, rewrite lets rules in any file affect all other- files. print --auto uses standard directive scoping; rules affect+ o with multiple files, rewrite lets rules in any file affect all other+ files. print --auto uses standard directive scoping; rules affect only child files. - o rewrite's query limits which transactions can be rewritten; all are+ o rewrite's query limits which transactions can be rewritten; all are printed. print --auto's query limits which transactions are printed. - o rewrite applies rules specified on command line or in the journal.+ o rewrite applies rules specified on command line or in the journal. print --auto applies rules specified in the journal. roi roi- Shows the time-weighted (TWR) and money-weighted (IRR) rate of return+ Shows the time-weighted (TWR) and money-weighted (IRR) rate of return on your investments. - This command assumes that you have account(s) that hold nothing but+ This command assumes that you have account(s) that hold nothing but your investments and whenever you record current appraisal/valuation of these investments you offset unrealized profit and loss into account(s) that, again, hold nothing but unrealized profit and loss. - Any transactions affecting balance of investment account(s) and not- originating from unrealized profit and loss account(s) are assumed to+ Any transactions affecting balance of investment account(s) and not+ originating from unrealized profit and loss account(s) are assumed to be your investments or withdrawals. - At a minimum, you need to supply a query (which could be just an ac-+ At a minimum, you need to supply a query (which could be just an ac- count name) to select your investments with --inv, and another query to identify your profit and loss transactions with --pnl. - It will compute and display the internalized rate of return (IRR) and- time-weighted rate of return (TWR) for your investments for the time- period requested. Both rates of return are annualized before display,+ It will compute and display the internalized rate of return (IRR) and+ time-weighted rate of return (TWR) for your investments for the time+ period requested. Both rates of return are annualized before display, regardless of the length of reporting interval. stats stats Show some journal statistics. - 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. Example:@@ -2594,14 +2595,14 @@ Commodities : 1 ($) Market prices : 12 ($) - This command also supports output destination and output format selec-+ This command also supports output destination and output format selec- tion. tags tags- List all the tag names used in the journal. With a TAGREGEX argument,- only tag names matching the regular expression (case insensitive) are- shown. With QUERY arguments, only transactions matching the query are+ List all the tag names used in the journal. With a TAGREGEX argument,+ only tag names matching the regular expression (case insensitive) are+ shown. With QUERY arguments, only transactions matching the query are considered. With --values flag, the tags' unique values are listed in- stead. @@ -2609,13 +2610,13 @@ test Run built-in unit tests. - This command runs the unit tests built in to hledger and hledger-lib,- printing the results on stdout. If any test fails, the exit code will+ This command runs the unit tests built in to hledger and hledger-lib,+ printing the results on stdout. If any test fails, the exit code will be non-zero. - This is mainly used by hledger developers, but you can also use it to- sanity-check the installed hledger executable on your platform. All- tests are expected to pass - if you ever see a failure, please report+ This is mainly used by hledger developers, but you can also use it to+ sanity-check the installed hledger executable on your platform. All+ tests are expected to pass - if you ever see a failure, please report as a bug! This command also accepts tasty test runner options, written after a --@@ -2624,32 +2625,32 @@ $ hledger test -- -pData.Amount --color=never - For help on these, see https://github.com/feuerbach/tasty#options (--+ For help on these, see https://github.com/feuerbach/tasty#options (-- --help currently doesn't show them). 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+ 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: 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:@@ -2664,7 +2665,7 @@ 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@@ -2684,14 +2685,14 @@ count, but it's superseded now by the built-in roi command. Experimental add-ons- These are available in source form in the hledger repo's bin/ direc-- tory. They may be less mature and documented than built-in commands.+ These are available in source form in the hledger repo's bin/ direc-+ tory. They may be less mature and documented 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. chart@@ -2701,21 +2702,21 @@ hledger-check.hs checks more powerful account balance assertions. 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). LIMITATIONS- 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@@ -2731,33 +2732,33 @@ 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 re-- member 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 re-+ member 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@@ -2776,7 +2777,7 @@ $ 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@@ -2797,7 +2798,7 @@ 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) @@ -2811,7 +2812,7 @@ 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) @@ -2819,4 +2820,4 @@ -hledger 1.16.1 December 2019 hledger(1)+hledger 1.16.2 January 2020 hledger(1)