Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse transaction metadata #13

Open
noahfrederick opened this issue Jul 7, 2021 · 2 comments
Open

Parse transaction metadata #13

noahfrederick opened this issue Jul 7, 2021 · 2 comments

Comments

@noahfrederick
Copy link

Transaction notes may contain tags, which should be parsed:

https://www.ledger-cli.org/3.0/doc/ledger3.html#Metadata

Simple Tag

2020-12-02 Market  ; :Tag:
    Expenses:Food:Groceries

Tagged Posting

2020-12-02 Market
    Expenses:Food:Groceries
        ; :Tag:

Multiple Tags

2020-12-02 Market  ; :Tag1:Tag2:
    Expenses:Food:Groceries

Tags with Values

2020-12-02 Market
    ; Tag1: Value 1
    ; Tag2: Value 2
    Expenses:Food:Groceries

Tags with Typed Values

2020-12-02 Market
    ; Count:: 10
    ; SomeDate:: [1999-12-02]
    Expenses:Food:Groceries
@afh
Copy link
Contributor

afh commented Feb 8, 2023

Auxiliary / effective dates can also be specified in a posting's metadata, e.g. ; [=2009/03/01] (see section on Effective Dates in the Ledger manual):

2008/10/16 * (2090) Bountiful Blessings Farm
    Expenses:Food:Groceries                  $ 37.50  ; [=2008/10/01]
    Expenses:Food:Groceries                  $ 37.50  ; [=2008/11/01]
    Expenses:Food:Groceries                  $ 37.50  ; [=2008/12/01]
    Expenses:Food:Groceries                  $ 37.50  ; [=2009/01/01]
    Expenses:Food:Groceries                  $ 37.50  ; [=2009/02/01]
    Expenses:Food:Groceries                  $ 37.50  ; [=2009/03/01]
    Assets:Checking

@cbarrete
Copy link
Owner

From what I remember looking at this when this issue was raised, this is likely to require an external scanner to cover all cases and I have not gotten around to writing one, especially since that's not a very useful feature to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants