ledger-mode
ledger-mode copied to clipboard
[BUG] org-cycle/org-fold with outline mode has stopped working in ledger mode
Heya awesome ledge-mode maintainers!
This might seem like a minor thing, but it is making my monthly accounting hellish since I have long complex files for both personal and business accounting. That is, all of a sudden, my tab no longer folds/unfolds sections of my ledger files.
Here's my config. I've changed nothing of late other than using straight-pull-all to grab updated packages. This appears to be either related to some change in ledger-mode or in org-fold's functionality (it might be the latter).
;; ========== Ledger mode =========
(use-package ledger-mode
:straight t
:defer t
:hook
(ledger-mode . outline-minor-mode)
:bind
(:map ledger-mode-map
("TAB" . org-cycle))
:config
(font-lock-add-keywords 'ledger-mode outline-font-lock-keywords)
:mode
("\\.ledger$" . ledger-mode)
)
At the monent, when attempting to fold on a line with a heading denoted by * with TAB now, I'm getting this message from emacs:
Calling 'org-fold-core-region' with missing SPEC
Org-mode files fold fine themselves, so a bi puzled as to whzat could be wrong, but it's killing me in terms of buzzsaw-ing through my monthly finances atm. Could really use some help on what might be wrong.
(and also, while I have the chance, thank you maintainers for making this plugin. It is by far the best of all the plugins across IDEs for making ledger a super useful tool. I know, I've tried them all. =] ).
I should point out that this still seem to work with outline mode since I can fold major and minor sections with C-C @ C-C so this may be something related to changes in org-fold/org-cycle. It is really strange as it just suddenly stopped working.
I feel like if org-cycle was working for you previously in ledger-mode then that was more a matter of luck than anything that the ledger-mode maintainers could influence for you.
Lol... Hmmm, I see. Well, it was super, super handy lemme tell ya.
So, I am assuming this means that this is a problem with org-mode more than ledger then? (one of the hardest things I find about troubleshooting things going wrong in emacs is on which package to poke at... :-/ ).
(and thanks for replying so promptly!)
I am assuming this means that this is a problem with org-mode more than ledger then?
It looks that way to me!
But outline-minor-mode still works. Is it a case you don't like its default bindings? They can always be changed to your liking. An alternative is if you happen to use consult then consult-outline` will present the outline headings via its completing read interface.
In any case, I think this issue can be closed as it is unrelated to ledger-mode.