ledger is a scriptable double-entry accounting system for the command-line. Unlike most other accounting software, ledger eschews opaque binary file formats and embraces a simple but well structured text file as its file format of choice. The file format ledger uses has the advantage of being trivial for both computers and humans to parse. So much so that ledger single-handedly spawned the Plain Text Accounting movement. This has lead to dozens of clones and support tools that all embrace ledger's file format, the most prominent of which are hledger (Haskell) and Beancount (Python).
USE flags for app-office/ledger Double-entry accounting system with a command-line reporting interface
|Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
|Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of globally
|Add optional support/bindings for the Python language
emerge --ask app-office/ledger
ledger has an extensive list of command-line options detailed in its man page, nearly any one of which can be turned into an environment variable. When an environment variable conflicts with a command-line option, the command-line option takes precedence.
- ~/.ledgerrc - user specific configuration file.
How do I import a CSV file into ledger?
ledger comes with a convert command that readily accepts a CSV file as input. The only issue is that it must be told how to parse and date codes it encounters as there are several standards in use internationally:
ledger convert download.csv --input-date-format "%Y/%m/%d"
How do I convert files from Quickbooks?
This is not directly supported, but there are third party tools that will do this, such as:
How do I import files from GNUCash?
This isn't directly supported either but simple third party scripts can do this, such as:
emerge --ask --depclean --verbose app-office/ledger
- bc — arbitrary-precision fixed-point mathematical scripting language
- sc-im — a terminal-based spreadsheet and calculator with vim-like key bindings