LinuxCommandLibrary

hledger-aregister

Show register-style report of account transactions

TLDR

Show transactions and running balance in the assets:bank:checking account

$ hledger [[areg|aregister]] assets:bank:checking
copy

Show transactions and running balance in the first account named *savings*
$ hledger [[areg|aregister]] savings
copy

Show the checking account's cleared transactions, with a specified width
$ hledger [[areg|aregister]] checking [[-C|--cleared]] [[-w|--width]] [120]
copy

Show the checking register, including transactions from forecast rules
$ hledger [[areg|aregister]] checking --forecast
copy

SYNOPSIS

hledger-aregister [OPTIONS] [ACCOUNT_QUERY...]

PARAMETERS

ACCOUNT_QUERY
    A pattern or name of an account (or accounts) for which the register should be displayed. This can be a full account name (e.g., "Assets:Bank:Checking") or a regular expression that matches multiple accounts (e.g., "^Expenses"). All transactions affecting matching accounts will be included in the report.

Other hledger register options
    hledger-aregister typically acts as a thin wrapper around hledger register. Therefore, most options available to hledger register (such as -f FILE to specify the ledger file, -p PERIOD to filter by date period, -D to display daily running balances, -O FORMAT for output format, etc.) can often be passed directly to hledger-aregister and will be forwarded to the underlying hledger register command.

DESCRIPTION

hledger-aregister is a convenience wrapper script built around the core hledger register command. Its primary function is to display a detailed register of transactions for one or more accounts, along with their running balances. It is particularly useful for quickly inspecting the chronological financial activity of specific accounts or groups of accounts.

While hledger register provides similar functionality, hledger-aregister streamlines the process, often by automatically setting common options like the --monthly (-M) flag for a clearer, aggregated view, or by simplifying the account matching syntax. It typically parses account names or patterns provided as arguments and forwards them along with other standard hledger options to hledger register, making it easier to drill down into account-specific data within your plain text ledger.

CAVEATS

hledger-aregister is often a community-contributed script or an example provided with hledger, rather than a core binary. Its exact implementation may vary depending on how it's installed or written (e.g., it might be a simple bash script that just calls hledger register -M "$@").

Its behavior is largely dependent on the underlying hledger register command; any limitations or features of that command apply. It typically defaults to --monthly (-M) output, which might not be desired for all use cases, though this can usually be overridden by passing conflicting hledger register options.

COMMON USE CASES

Quick Account Audit: Quickly review all transactions for a specific bank account, credit card, or investment account.

Expense Tracking: Monitor spending within a particular expense category like "Expenses:Food" or "Expenses:Utilities" to understand expenditure patterns.

Drilling Down: After viewing an overall balance report, use hledger-aregister to inspect the granular details of specific accounts that pique your interest.

CUSTOMIZATION

Since hledger-aregister is often a simple shell script, users have the flexibility to modify it to suit their specific needs. This might include adding default options (e.g., always filtering by a specific period), changing output formats, or integrating it with other scripts for highly customized financial reporting workflows.

HISTORY

hledger, the plain text accounting system, was first released in 2008 by Simon Michael. The hledger-aregister script, like many other helper scripts in the hledger ecosystem (e.g., hledger-baltop), emerged from the community as a common utility. It was created to streamline a frequent reporting task for users – quickly viewing account-specific transaction registers – without requiring them to manually type all the options for hledger register repeatedly. It embodies the hledger philosophy of composable tools and leveraging plain text for flexible financial management.

SEE ALSO

hledger(1), hledger-register(1), hledger-balance(1), hledger-baltop(1)

Copied to clipboard