branch: externals/dtache commit b121de820cf28ed507194b9c4cde90ac9ca672d8 Author: Rose Osterheld <d...@roeli.org> Commit: Niklas Eklund <niklas.ekl...@posteo.net>
Handle carriage motion when opening a session Properly handle characters like carriage returns and backspaces in session output. The package can now properly handle these characters upon viewing a session. For now it will handle the previous output when tailing a session but any new output will not be handled. --- dtache.el | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dtache.el b/dtache.el index 03cf504a4d..2c1294fe2d 100644 --- a/dtache.el +++ b/dtache.el @@ -45,6 +45,7 @@ (require 'ansi-color) (require 'autorevert) +(require 'comint) (require 'notifications) (require 'filenotify) (require 'simple) @@ -1302,6 +1303,8 @@ If event is cased by an update to the `dtache' database, re-initialize (define-derived-mode dtache-log-mode nil "Dtache Log" "Major mode for `dtache' logs." (when dtache-filter-ansi-sequences + (comint-carriage-motion (point-min) (point-max)) + (set-buffer-modified-p nil) (ansi-color-apply-on-region (point-min) (point-max))) (read-only-mode t)) @@ -1323,6 +1326,8 @@ If event is cased by an update to the `dtache' database, re-initialize (setq-local auto-revert-verbose nil) (auto-revert-tail-mode) (when dtache-filter-ansi-sequences + (comint-carriage-motion (point-min) (point-max)) + (set-buffer-modified-p nil) (add-hook 'after-revert-hook #'dtache--ansi-color-tail nil t) (ansi-color-apply-on-region (point-min) (point-max))) (read-only-mode t))