diff options
author | Craig Earls <enderw88@gmail.com> | 2013-03-08 19:33:16 -0500 |
---|---|---|
committer | Craig Earls <enderw88@gmail.com> | 2013-03-08 19:33:16 -0500 |
commit | bfe360d4c992caf2e7da09ab058599c0404f1348 (patch) | |
tree | aef00997084ef1a4cd9d329454c73a667720202c | |
parent | 404e84cd445d41b3f2fc6cd775babf12864fcefc (diff) | |
download | fork-ledger-bfe360d4c992caf2e7da09ab058599c0404f1348.tar.gz fork-ledger-bfe360d4c992caf2e7da09ab058599c0404f1348.tar.bz2 fork-ledger-bfe360d4c992caf2e7da09ab058599c0404f1348.zip |
Reconcile date configuration is pulled from ledgerrc
-rw-r--r-- | lisp/ldg-reconcile.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/ldg-reconcile.el b/lisp/ldg-reconcile.el index 9f1a220c..802cb3b4 100644 --- a/lisp/ldg-reconcile.el +++ b/lisp/ldg-reconcile.el @@ -285,13 +285,15 @@ POSTING is used in `ledger-clear-whole-transactions' is nil." (if (looking-at "(") (read (current-buffer))))))))) ;current-buffer is the *temp* created above (if (and ledger-success (> (length xacts) 0)) - (progn + (let ((date-format (cdr (assoc "date-format" ledger-environment-alist)))) (dolist (xact xacts) (dolist (posting (nthcdr 5 xact)) (let ((beg (point)) (where (ledger-marker-where-xact-is xact posting))) (insert (format "%s %-4s %-30s %-30s %15s\n" - (format-time-string "%Y/%m/%d" (nth 2 xact)) + (format-time-string (if date-format + date-format + "%Y/%m/%d") (nth 2 xact)) (if (nth 3 xact) (nth 3 xact) "") |