bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: why must bash zap last search string just because we hit ^C?


From: Dennis Williamson
Subject: Re: why must bash zap last search string just because we hit ^C?
Date: Fri, 16 Oct 2015 15:56:01 -0500



On Fri, Oct 16, 2015 at 1:50 PM, Chet Ramey <chet.ramey@case.edu> wrote:
On 10/16/15 3:19 AM, 積丹尼 Dan Jacobson wrote:
> Type ^Racb^C^R^R
> (Search backwards for abc, then hit ^C, then try searching backwards
> some more using the last search string.)
>
> My problem is why must bash zap the memory of abc just because we hit ^C?

^C rudely aborts the entire operation.  Why assume you want to save any
of the context?

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


^G also interrupts reverse-i-search and also doesn't retain the interrupted search string in the same way as ^C (^R^R recalls the previous search that was terminated by enter or cursor move, etc. - (e.g. isearch-terminators) - instead of the interrupted one).

--
Visit serverfault.com to get your system administration questions answered.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]