Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upAdd support for ledger plain text accounting format #766
Comments
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
colindean
Sep 4, 2017
I've got a start on it in https://github.com/colindean/rouge/blob/colindean/ledger/lib/rouge/lexers/ledger.rb but I'm really struggling with the state machine. I can't seem to get it to recognize the commodity token that follows the amount in a transaction's line item. Then, I can't get it to start over again processing the next line item in a transaction. I've tried littering with :pop! to no avail.
You can see an (inexhaustive) example here. I've been using Rouge's built-in tester with http://localhost:9292/ledger.
colindean
commented
Sep 4, 2017
|
I've got a start on it in https://github.com/colindean/rouge/blob/colindean/ledger/lib/rouge/lexers/ledger.rb but I'm really struggling with the state machine. I can't seem to get it to recognize the commodity token that follows the amount in a transaction's line item. Then, I can't get it to start over again processing the next line item in a transaction. I've tried littering with You can see an (inexhaustive) example here. I've been using Rouge's built-in tester with http://localhost:9292/ledger. |
colindean commentedSep 4, 2017
I'd like to be able to parse ledger format. Ledger-CLI is an open source accounting tool that started the plaintext accounting ecosystem.