jjc@UUNET.UU.NET (James Clark) (06/13/89)
bash 0.99 doesn't correctly deal with ^ as a word designator. This
fixes the problem:
*** history.c.dist Tue Jun 13 11:06:56 1989
--- history.c Tue Jun 13 11:35:04 1989
***************
*** 985,990 ****
--- 985,991 ----
get_last:
if (spec[i] == '^') {
+ i++;
last = 1;
goto get_args;
}
It would be nice if the key binding mechanism was able to cope with
the escape sequences generated by arrow keys.
James Clark
jjc@jclark.uucp
chet@kiwi.CWRU.EDU (Chet Ramey) (06/14/89)
In article <8906131046.AA24780@jclark.uucp> jclark!jjc@UUNET.UU.NET (James Clark) writes: > >It would be nice if the key binding mechanism was able to cope with >the escape sequences generated by arrow keys. The patches I posted added this capability. I talked to Brian about it, and they might be in 1.00, though the way I did it isn't really "right" (I should have used indirected keymaps to allow binding to multi-character strings, but took the easy way out. Hey, it works for me.). Chet Ramey Chet Ramey Network Services Group, CWRU chet@{cwjcc,pirate}.INS.CWRU.Edu "The flagon with the dragon has the potion with the poison; the vessel with the pestle holds the brew that is true!"
andrewt@WATSNEW.WATERLOO.EDU (Andrew Thomas) (06/14/89)
> > > >It would be nice if the key binding mechanism was able to cope with > >the escape sequences generated by arrow keys. > > The patches I posted added this capability. I talked to Brian about it, and > they might be in 1.00, though the way I did it isn't really "right" (I should > have used indirected keymaps to allow binding to multi-character strings, > but took the easy way out. Hey, it works for me.). I have been using bash since 0.87, and have never had a problem with binding the arrow keys. My arrow keys produce the following escape codes (vt220 terminal): up arrow ESC [ A down arrow ESC [ B right arrow ESC [ C left arrow ESC [ D my .inputrc looks like this: Meta-[: prefix-meta Meta-A: previous-history Meta-B: next-history Meta-C: forward-char Meta-D: backward-char I haven't figured out how to bind the vt220 function keys which generate sequences like 'ESC [ 1 7 ~' and 'ESC [ 1 8 ~'. It just occurred to me that this is what this discussion is really about. Andrew Thomas andrewt@watsnew.waterloo.edu Systems Design Eng. University of Waterloo