emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/csv2ledger 102890f078 103/190: Update the README.


From: ELPA Syncer
Subject: [nongnu] elpa/csv2ledger 102890f078 103/190: Update the README.
Date: Sun, 2 Jun 2024 15:59:49 -0400 (EDT)

branch: elpa/csv2ledger
commit 102890f078dec24490632b1df6b798db6e51335e
Author: Joost Kremers <joost.kremers@ipsoft.com>
Commit: Joost Kremers <joost.kremers@ipsoft.com>

    Update the README.
---
 README.md | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index ac971e97a1..02ed4bc0f2 100644
--- a/README.md
+++ b/README.md
@@ -163,7 +163,18 @@ You may also notice that the transaction alist does not 
contain a value for `tit
 
 ### Setting the amount ###
 
-As already mentioned above, a CSV file may contain the amount of a transaction 
in a single column, or it may use separate columns for amounts debit and 
amounts credit.
+As already mentioned above, a CSV file may contain the amount of a transaction 
in a single column, or it may use separate columns for amounts debit and 
amounts credit. The function that creates the actual ledger entry requires the 
`amount` field to be present, however. Therefore, if there is no `amount` field 
in `c2l-csv-columns`, `csv2ledger` assumes that `credit` and `debit` are 
present. It does this by setting the variable `c2l-amount-function`. This 
variable is similar to `c2l-title- [...]
+
+The variable `c2l-amount-function` is actually a user option, which means that 
you can set it to a user-defined function if you like, which may be useful if 
your CSV file is structured in some strange way that I haven't envisaged.
+
+One point to keep in mind: the amount in the debit field must be a negative 
amount, i.e., it must have a minus sign. If this is not the case, the easiest 
way to change this is in `c2l-field-modify-functions`, though in principle 
`c2l-transaction-modify-function` and `c2l-amount-function` could be used as 
well.
+
+
+### Creating the entry ###
+
+After all modification functions have been called, the resulting transaction 
is passed to the function in `c2l-entry-function` . The default value of this 
option is the function `c2l-compose-entry`, which creates entries in the form 
shown above. If that format does not suit your needs, you can use a custom 
function instead. It should take the transaction as an alist and return a 
string that can be inserted into a ledger buffer.
+
+
 
 TODO
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]