[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#36034: [PATCH] Zsh extended_history shows up in comint input ring
From: |
Lars Ingebrigtsen |
Subject: |
bug#36034: [PATCH] Zsh extended_history shows up in comint input ring |
Date: |
Sun, 23 Jun 2019 18:53:54 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
Matthew Bauer <mjbauer95@gmail.com> writes:
> The format of this line looks like this:
>
> : <beginning time>:<elapsed seconds>;<command>
>
> This patch just skips those timestamp to get the <command> part.
[...]
> --- a/lisp/comint.el
> +++ b/lisp/comint.el
> @@ -976,7 +976,11 @@ See also `comint-input-ignoredups' and
> `comint-write-input-ring'."
> (setq start
> (if (re-search-backward comint-input-ring-separator
> nil t)
> - (match-end 0)
> + (progn
> + ;; Skip zsh extended_history stamps
> + (re-search-forward ":
> [[:digit:]]+:[[:digit:]]+;" nil t)
> +
> + (match-end 0))
> (point-min)))
> (setq history (buffer-substring start end))
> (goto-char start)
I'm not that familiar with the comint/shell code... but this is done
in the central comint code, so it would do this for all the modes that
use comint? Couldn't that lead to problems in these other modes that
aren't doing this timestamp thing?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
- bug#36034: [PATCH] Zsh extended_history shows up in comint input ring,
Lars Ingebrigtsen <=