[Top][All Lists]

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

Re: stty settings override ~/.inputrc?

From: Chet Ramey
Subject: Re: stty settings override ~/.inputrc?
Date: Fri, 05 Aug 2005 11:43:11 -0400
User-agent: Mozilla Thunderbird 1.0.6 (Macintosh/20050716)

Eric Blake wrote:
> A complaint was raised on the cygwin list, where the user had default
> terminal settings (lnext set to ^v), and this line in their ~/.inputrc:
> "\C-v":paste-from-clipboard
> This report is against bash-3.0.16/readline-5.0.
> Within a single line, hitting \C-x\C-r to re-read ~/.inputrc lets ctrl-v
> paste, but as soon as the user hits enter, readline is resetting the
> binding of ctrl-v back to quoted-insert (to match the stty settings of
> lnext).  Is this intentional behavior?  It would make more sense if
> ~/.inputrc settings overrode stty settings, rather than stty settings
> being forced onto key bindings every time the prompt is redisplayed.

Readline, beginning with version 5.0, reads the stty special character
settings and binds them to their readline equivalents each time
readline() is called.  It reads ~/.inputrc once per `program'.

I made this change in response to many bug reports, over a number of
years, complaining that changes made with stty were not reflected in
the readline key bindings.

Since the traditional behavior is to read ~/.inputrc once per program
invocation, you can't have inputrc settings override stty settings
without changing readline to re-read inputrc on each call, which I
did not want to do.

Readline-5.1 makes reading the stty characters a settable option.

``The lyf so short, the craft so long to lerne.'' - Chaucer
( ``Discere est Dolere'' -- chet )
Chet Ramey, ITS, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/

reply via email to

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