I'm pleased to announce a new version of total_recall.

total_recall is a rubygem that helps you turn any csv into a Ledger journal.

Best to explain what it does using a sample yaml-config:
---
:total_recall:
  :version: 0.5.0
:template:
  :raw: |-
    ; -*- ledger -*-¬

    {{# transactions}}
    {{date}} {{{description}}}
      {{to}}    {{currency}} {{amount}}
      {{from}}

    {{/ transactions}}

:csv:
  #:file: total_recall.csv
  :raw: |-
    "03.11.2013","Foo","04.11.2013","1.638,00"
    "03.11.2013","Bar","04.11.2013","-492,93"

:context:
  :transactions:
    :__defaults__:
      :currency: EUR
      :from: !!proc |
        ask_account("What account provides these transactions?", default: 
'Assets:Checking')
    :date: !!proc row[0]
    :description: !!proc row[1]
    :amount: !!proc row[3]
    :to: !!proc |
      render_row(columns: [0, 1, 3])
      ask_account("To what account did the money go?")

The main ingredients of the config are:
- template:
a mustache template (http://mustache.github.io/mustache.5.html) containing a 
transactions-section
- csv:
either a raw snippet (to quickly test your context) or a file
- context:
describes how the data for the template should be extracted from the csv.

The context is where the magic happens.
You can either assign a value (like currency in the above example), evaluate 
some Ruby (using the '!!proc' notation) or prompt the user for input.

install (requires ruby >=1.9.3): gem install total_recall
quickstart: total_recall sample
        this will generate an annotated (and more extensive) config-file.
source: https://github.com/eval/total_recall

Best,
Gert


-- 
ThinkCreate
+31 (0)6 47128181
www.thinkcreate.nl

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to