mirror of
https://git.sr.ht/~magic_rb/dotfiles
synced 2024-12-11 09:22:02 +01:00
46 lines
1.7 KiB
Org Mode
46 lines
1.7 KiB
Org Mode
|
:PROPERTIES:
|
||
|
:header-args:emacs-lisp: :comments link :results none
|
||
|
:ID: 2f95ff8f-b030-4c90-8296-29c1cc8b2b0c
|
||
|
:END:
|
||
|
#+title: HLedger
|
||
|
#+filetags: emacs-load
|
||
|
|
||
|
For hledger, it's possible to use =ledger-mode= instead of =hledger-mode=. We'll see how it goes. It does require some convincing though.
|
||
|
|
||
|
#+begin_src emacs-lisp
|
||
|
(use-package ledger-mode
|
||
|
:straight t
|
||
|
:config
|
||
|
(setq ledger-binary-path "ledger-hledger")
|
||
|
(setq ledger-default-date-format ledger-iso-date-format)
|
||
|
(setq ledger-report-links-in-register nil)
|
||
|
(setq ledger-report-native-highlighting-arguments '("--color=always"))
|
||
|
(setq ledger-report-auto-width nil)
|
||
|
(setq ledger-reconcile-default-commodity "EUR")
|
||
|
(setq ledger-report-use-header-line t)
|
||
|
(setq ledger-report-use-native-highlighting t)
|
||
|
(setq ledger-report-auto-refresh-sticky-cursor t)
|
||
|
(setq ledger-report-use-strict t)
|
||
|
(setq ledger-highlight-xact-under-point t)
|
||
|
(setq ledger-copy-transaction-insert-blank-line-after t)
|
||
|
(add-to-list 'auto-mode-alist '("\\.\\(h?ledger\\|journal\\|j\\)$" . ledger-mode))
|
||
|
(setq ledger-report-balance
|
||
|
(list "bal" (concat ledger-binary-path " --strict -f %(ledger-file) bal")))
|
||
|
|
||
|
(setq ledger-report-reg
|
||
|
(list "reg" (concat ledger-binary-path " --strict -f %(ledger-file) reg")))
|
||
|
|
||
|
(setq ledger-report-payee
|
||
|
(list "payee" (concat ledger-binary-path " --strict -f %(ledger-file) reg @%(payee)")))
|
||
|
|
||
|
(setq ledger-report-account
|
||
|
(list "account" (concat ledger-binary-path " --strict -f %(ledger-file) reg %(account)")))
|
||
|
|
||
|
(setq ledger-reports
|
||
|
(list ledger-report-balance
|
||
|
ledger-report-reg
|
||
|
ledger-report-payee
|
||
|
ledger-report-account)))
|
||
|
#+end_src
|
||
|
|