Common Ledger CLI Commands (Source)
Income vs expenses this month?
ledger balance income expenses --period "this month"What did my budget look like at a certain date?
ledger balance budget --end 2018-01-02This is how it looked at the end of the day on Jan 1, 2018.
How much is in the checking account right now?
ledger balance checkingWhat is our net worth?
ledger balance ^assets ^liabilities --realHow much money have we made?
ledger balance incomeHow much money have we made from our salaries?
ledger balance income:salaryHow much do we spend each month on x?
ledger register -M expenses:groceries:foodGroup transactions by payee
ledger register --by-payeeOnly show uncleared transactions
ledger register --unclearedDo I have enough budgeted to pay off my credit cards?
ledger balance creditcardIt should be $0.00. If it’s not $0.00, run this with different dates to find the problem:
ledger balance creditcard --end 2018-02-01Import
Change Chase checking from:
Details,Posting Date,Description,Amount,Type,Balance,Check or Slip #to:
,Date,Payee,Amount,,,CodeChange Chase Credit Card from:
Type,Trans Date,Post Date,Description,Amountto:
,Date,Posted,Payee,Amountledger convert ~/Downloads/checking.CSV --input-date-format "%m/%d/%Y" --invert --account Assets:Checking --rich-data -f budget.ledger --auto-match --pager lessExpenses each month (sorted)
ledger -M --period-sort "(amount)" reg ^expensesThis will show all expenses, grouped by month and sorted by the amount.
How much do we spend on credit cards each month?
ledger -M -r --display 'account=~/creditcard/' reg ^expenses