diff options
| author | Eli Zaretskii | 2005-12-16 12:16:35 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2005-12-16 12:16:35 +0000 |
| commit | 59be5828de98814b8aa32718bf2b6196db085db1 (patch) | |
| tree | 14b1a266ca5a53cdbb2e2168d3ae486b49c218f5 | |
| parent | 2ac7dc550572040e2f072a377bbd4cb6ea50ffe7 (diff) | |
| download | emacs-59be5828de98814b8aa32718bf2b6196db085db1.tar.gz emacs-59be5828de98814b8aa32718bf2b6196db085db1.zip | |
(term-emulate-terminal): Let term-handle-ansi-terminal-messages override
what Bash says about its current directory.
| -rw-r--r-- | lisp/term.el | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/lisp/term.el b/lisp/term.el index 14d4fb9a5ab..62728f45a08 100644 --- a/lisp/term.el +++ b/lisp/term.el | |||
| @@ -2687,13 +2687,17 @@ See `term-prompt-regexp'." | |||
| 2687 | (buffer-undo-list t) | 2687 | (buffer-undo-list t) |
| 2688 | (selected (selected-window)) | 2688 | (selected (selected-window)) |
| 2689 | last-win | 2689 | last-win |
| 2690 | handled-ansi-message | ||
| 2690 | (str-length (length str))) | 2691 | (str-length (length str))) |
| 2691 | (save-selected-window | 2692 | (save-selected-window |
| 2692 | 2693 | ||
| 2693 | ;; Let's handle the messages. -mm | 2694 | ;; Let's handle the messages. -mm |
| 2694 | 2695 | ||
| 2695 | (setq str (term-handle-ansi-terminal-messages str)) | 2696 | (let* ((newstr (term-handle-ansi-terminal-messages str))) |
| 2696 | (setq str-length (length str)) | 2697 | (if (not (eq str newstr)) |
| 2698 | (setq handled-ansi-message t | ||
| 2699 | str newstr))) | ||
| 2700 | (setq str-length (length str)) | ||
| 2697 | 2701 | ||
| 2698 | (if (marker-buffer term-pending-delete-marker) | 2702 | (if (marker-buffer term-pending-delete-marker) |
| 2699 | (progn | 2703 | (progn |
| @@ -2849,7 +2853,8 @@ See `term-prompt-regexp'." | |||
| 2849 | ((eq char ?\017)) ; Shift In - ignored | 2853 | ((eq char ?\017)) ; Shift In - ignored |
| 2850 | ((eq char ?\^G) ;; (terminfo: bel) | 2854 | ((eq char ?\^G) ;; (terminfo: bel) |
| 2851 | (beep t)) | 2855 | (beep t)) |
| 2852 | ((eq char ?\032) | 2856 | ((and (eq char ?\032) |
| 2857 | (not handled-ansi-message)) | ||
| 2853 | (let ((end (string-match "\r?$" str i))) | 2858 | (let ((end (string-match "\r?$" str i))) |
| 2854 | (if end | 2859 | (if end |
| 2855 | (funcall term-command-hook | 2860 | (funcall term-command-hook |