Double-entry accounting ledger parser
Perl 6
Switch branches/tags
Nothing to show
Failed to load latest commit information.
lib make tests green, s/Match/TXN::Parser::Grammar Apr 22, 2017
t make tests green, s/Match/TXN::Parser::Grammar Apr 22, 2017
.hgignore get t/data from atweiden/txn-examples May 10, 2016
.peru.yml reup peru, git checkout commit ID Dec 3, 2016
.travis.yml replace panda with zef Aug 11, 2017
META6.json Use SPDX identifier in license field of META6.json Apr 21, 2017
UNLICENSE Initial import Apr 28, 2016


Double-entry accounting ledger parser


use TXN::Parser;

# parse ledger from string
my $txn = Q:to/EOF/;
2014-01-01 "I started the year with $1000 in Bankwest"
  Assets:Personal:Bankwest:Cheque    $1000 USD
  Equity:Personal                    $1000 USD
my TXN::Parser::AST::Entry @entry = TXN::Parser.parse($txn).made;

# parse ledger from file
my $file = 'sample.txn';
my TXN::Parser::AST::Entry @entry = TXN::Parser.parsefile($file).made;



Test Dependencies

To run the tests:

$ git clone && cd txn-parser
$ peru --file=.peru.yml --sync-dir="$PWD" sync
$ PERL6LIB=lib prove -r -e perl6


This is free and unencumbered public domain software. For more information, see or the accompanying UNLICENSE file.