I need to investigate text log files a lot. Emacs with auto-revert-tail-mode
does the job almost fine, except when there are long lines (JSON/XML dumps, 1-40kb large).
In that case Emacs lags a lot.
I use fundamental-mode
+ add few font-lock-add-keywords
by (highlighting for INFO/DEBUG/ERROR & for date/time):
http://hg.defun.work/dot-emacs/file/tip/mylisp/log4-hi-mode.el
Even with plain fundamental-mode
Emacs is unresponsible. I tried debug on error on C-g and the stacktrace is only native rendering function redisplay_internal
.
Just writing the post I tried so-long-mode
instead of fundamental-mode
and it is much better but still noticeably lagging. Few extra font-lock-add-keywords
in so-long-mode
doesn't have huge impact: movement is just a bit slower than without.
I don't like to open Notepad++ just for log files, though it might be the proper solution...
Any suggestions on debugging long line issue?
Could we expect Emacs rendering of long lines improved?
I'm with Cygwin Emacs W32 27.2. Almost the same situation with Emacs 27.1 in WSL1 terminal. so-long-mode
provides better experience, few font-lock-add-keywords
ruin smoothness of movement.
UPDATE I really need some highlighting for log files (date/time + INFO/DEBUG/ERROR): I expect some help from the tool.