No easy way to disable
Atemu opened this issue · comments
I needed to take a look at some line ending diffs and promptly ran into dandavison/delta#754 making it impossible to tell what's going on.
So as a workaround, I wanted to quickly disable magit-delta for the repo I was working on but I couldn't as it'd always re-enable itself in any new magit buffer (such as opening a diff).
This is due to the fact that it's enabled merely by adding a hook which are easy to work with as a user. I propose changing it to both a hook and a variable; the hook reading the variable to determine whether it should actually enable delta for this buffer. There should then be a global variable to disable magit-delta and perhaps a project-scoped one.
Hi @Atemu, yes I see you're right. It's implemented as an Emacs minor mode and so in theory M-x magit-delta-mode
should toggle it. But I see that it becomes reactivated. If you work on this, if possible, it would be good to bear in mind this PR, which I think might be touching the lines of code you are referring to: #27