branch: externals/detached
commit 2d59684dd521523cdd3207decdf8d7120bc9805b
Author: Niklas Eklund <[email protected]>
Commit: Niklas Eklund <[email protected]>
Update removal of detached-message in output
Since the output from a detached session can contain either plain
text, or terminal data, the regular expression needs to be updated.
In the case of terminal data it contain a lot of escape sequences that
the previous expression was incompatible with.
---
detached.el | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/detached.el b/detached.el
index 14b3663f10..05a3fc9603 100644
--- a/detached.el
+++ b/detached.el
@@ -1153,7 +1153,8 @@ Optionally make the path LOCAL to host."
(defun detached--session-output (session)
"Return content of SESSION's output."
(let* ((filename (detached--session-file session 'log))
- (detached-message (rx (regexp "\n.detached-exit-code:.*"))))
+ (detached-message
+ (rx (regexp "\n.*\\[detached-exit-code: .*\\]"))))
(with-temp-buffer
(insert-file-contents filename)
(detached--maybe-watch-session session)