1 This document details the changes between this version, readline-6.2,
2 and the previous version, readline-6.1.
6 a. Fixed a bug that caused the unconverted filename to be added to the list of
7 completions when the application specified filename conversion functions.
9 b. Fixed a bug that caused the wrong filename to be passed to opendir when the
10 application has specified a filename dequoting function.
12 c. Fixed a bug when repeating a character search in vi mode in the case where
13 there was no search to repeat.
15 d. When show-all-if-ambiguous is set, the completion routines no longer insert
16 a common match prefix that is shorter than the text being completed.
18 e. The full set of vi editing commands may now be used in callback mode.
20 f. Fixed a bug that caused readline to not update its idea of the terminal
21 dimensions while running in `no-echo' mode.
23 h. Fixed a bug that caused readline to dump core if an application called
24 rl_prep_terminal without setting rl_instream.
26 i. Fixed a bug that caused meta-prefixed characters bound to incremental
27 search forward or backward to not be recognized if they were typed
30 j. The incremental search code treats key sequences that map to the same
31 functions as (default) ^G, ^W, and ^Y as equivalent to those characters.
33 k. Fixed a bug in menu-complete that caused it to misbehave with large
36 l. Fixed a bug that caused vi-mode yank-last-arg to ring the bell when invoked
37 at the end of the line.
39 m. Fixed a bug that made an explicit argument of 0 to yank-last-arg behave
40 as if it were a negative argument.
42 n. Fixed a bug that caused directory names in words to be completed to not
43 be dequoted correctly.
45 2. New Features in Readline
47 a. The history library does not try to write the history filename in the
48 current directory if $HOME is unset. This closes a potential security
49 problem if the application does not specify a history filename.
51 b. New bindable variable `completion-display-width' to set the number of
52 columns used when displaying completions.
54 c. New bindable variable `completion-case-map' to cause case-insensitive
55 completion to treat `-' and `_' as identical.
57 d. There are new bindable vi-mode command names to avoid readline's case-
58 insensitive matching not allowing them to be bound separately.
60 e. New bindable variable `menu-complete-display-prefix' causes the menu
61 completion code to display the common prefix of the possible completions
62 before cycling through the list, instead of after.
64 -------------------------------------------------------------------------------
65 This document details the changes between this version, readline-6.1,
66 and the previous version, readline-6.0.
68 1. Changes to Readline
70 a. The SIGWINCH signal handler now avoids calling the redisplay code if
71 one arrives while in the middle of redisplay.
73 b. Changes to the timeout code to make sure that timeout values greater
74 than one second are handled better.
76 c. Fixed a bug in the redisplay code that was triggered by a prompt
77 containing invisible characters exactly the width of the screen.
79 d. Fixed a bug in the redisplay code encountered when running in horizontal
82 e. Fixed a bug that prevented menu completion from properly completing
85 f. Fixed a redisplay bug caused by a multibyte character causing a line to
88 g. Fixed a bug that caused key sequences of two characters to not be
89 recognized when a longer sequence identical in the first two characters
92 h. Fixed a bug that caused history expansion to be attempted on $'...'
93 single-quoted strings.
95 i. Fixed a bug that caused incorrect redisplay when the prompt contained
96 multibyte characters in an `invisible' sequence bracketed by \[ and
99 j. Fixed a bug that caused history expansion to short-circuit after
100 encountering a multibyte character.
102 k. Fixed a bug that caused applications using the callback interface to not
103 react to SIGINT (or other signals) until another character arrived.
105 2. New Features in Readline
107 a. New bindable function: menu-complete-backward.
109 b. In the vi insertion keymap, C-n is now bound to menu-complete by default,
110 and C-p to menu-complete-backward.
112 c. When in vi command mode, repeatedly hitting ESC now does nothing, even
113 when ESC introduces a bound key sequence. This is closer to how
114 historical vi behaves.
116 d. New bindable function: skip-csi-sequence. Can be used as a default to
117 consume key sequences generated by keys like Home and End without having
120 e. New application-settable function: rl_filename_rewrite_hook. Can be used
121 to rewite or modify filenames read from the file system before they are
122 compared to the word to be completed.
124 f. New bindable variable: skip-completed-text, active when completing in the
125 middle of a word. If enabled, it means that characters in the completion
126 that match characters in the remainder of the word are "skipped" rather
127 than inserted into the line.
129 g. The pre-readline-6.0 version of menu completion is available as
130 "old-menu-complete" for users who do not like the readline-6.0 version.
132 h. New bindable variable: echo-control-characters. If enabled, and the
133 tty ECHOCTL bit is set, controls the echoing of characters corresponding
134 to keyboard-generated signals.
136 i. New bindable variable: enable-meta-key. Controls whether or not readline
137 sends the smm/rmm sequences if the terminal indicates it has a meta key
138 that enables eight-bit characters.
140 -------------------------------------------------------------------------------
141 This document details the changes between this version, readline-6.0,
142 and the previous version, readline-5.2.
144 1. Changes to Readline
146 a. Fixed a number of redisplay errors in environments supporting multibyte
149 b. Fixed bugs in vi command mode that caused motion commands to inappropriately
152 c. When using the arrow keys in vi insertion mode, readline allows movement
153 beyond the current end of the line (unlike command mode).
155 d. Fixed bugs that caused readline to loop when the terminal has been taken
156 away and reads return -1/EIO.
158 e. Fixed bugs in redisplay occurring when displaying prompts containing
159 invisible characters.
161 f. Fixed a bug that caused the completion append character to not be reset to
162 the default after an application-specified completion function changed it.
164 g. Fixed a problem that caused incorrect positioning of the cursor while in
165 emacs editing mode when moving forward at the end of a line while using
166 a locale supporting multibyte characters.
168 h. Fixed an off-by-one error that caused readline to drop every 511th
169 character of buffered input.
171 i. Fixed a bug that resulted in SIGTERM not being caught or cleaned up.
173 j. Fixed redisplay bugs caused by multiline prompts with invisible characters
174 or no characters following the final newline.
176 k. Fixed redisplay bug caused by prompts consisting solely of invisible
179 l. Fixed a bug in the code that buffers characters received very quickly in
180 succession which caused characters to be dropped.
182 m. Fixed a bug that caused readline to reference uninitialized data structures
183 if it received a SIGWINCH before completing initialzation.
185 n. Fixed a bug that caused the vi-mode `last command' to be set incorrectly
186 and therefore unrepeatable.
188 o. Fixed a bug that caused readline to disable echoing when it was being used
189 with an output file descriptor that was not a terminal.
191 p. Readline now blocks SIGINT while manipulating internal data structures
194 q. Fixed a bug in redisplay that caused readline to segfault when pasting a
195 very long line (over 130,000 characters).
197 r. Fixed bugs in redisplay when using prompts with no visible printing
200 s. Fixed a bug that caused redisplay errors when using prompts with invisible
201 characters and numeric arguments to a command in a multibyte locale.
203 t. Fixed a bug that caused redisplay errors when using prompts with invisible
204 characters spanning more than two physical screen lines.
206 2. New Features in Readline
208 a. A new variable, rl_sort_completion_matches; allows applications to inhibit
209 match list sorting (but beware: some things don't work right if
210 applications do this).
212 b. A new variable, rl_completion_invoking_key; allows applications to discover
213 the key that invoked rl_complete or rl_menu_complete.
215 c. The functions rl_block_sigint and rl_release_sigint are now public and
216 available to calling applications who want to protect critical sections
219 d. The functions rl_save_state and rl_restore_state are now public and
220 available to calling applications; documented rest of readline's state
223 e. A new user-settable variable, `history-size', allows setting the maximum
224 number of entries in the history list.
226 f. There is a new implementation of menu completion, with several improvements
227 over the old; the most notable improvement is a better `completions
230 g. The menu completion code now uses the rl_menu_completion_entry_function
231 variable, allowing applications to provide their own menu completion
234 h. There is support for replacing a prefix of a pathname with a `...' when
235 displaying possible completions. This is controllable by setting the
236 `completion-prefix-display-length' variable. Matches with a common prefix
237 longer than this value have the common prefix replaced with `...'.
239 i. There is a new `revert-all-at-newline' variable. If enabled, readline will
240 undo all outstanding changes to all history lines when `accept-line' is
243 -------------------------------------------------------------------------------
244 This document details the changes between this version, readline-5.2,
245 and the previous version, readline-5.1.
247 1. Changes to Readline
249 a. Fixed a problem that caused segmentation faults when using readline in
250 callback mode and typing consecutive DEL characters on an empty line.
252 b. Fixed several redisplay problems with multibyte characters, all having to
253 do with the different code paths and variable meanings between single-byte
254 and multibyte character redisplay.
256 c. Fixed a problem with key sequence translation when presented with the
259 d. Fixed a problem that prevented the `a' command in vi mode from being
260 undone and redone properly.
262 e. Fixed a problem that prevented empty inserts in vi mode from being undone
265 f. Fixed a problem that caused readline to initialize with an incorrect idea
266 of whether or not the terminal can autowrap.
268 g. Fixed output of key bindings (like bash `bind -p') to honor the setting of
269 convert-meta and use \e where appropriate.
271 h. Changed the default filename completion function to call the filename
272 dequoting function if the directory completion hook isn't set. This means
273 that any directory completion hooks need to dequote the directory name,
274 since application-specific hooks need to know how the word was quoted,
275 even if no other changes are made.
277 i. Fixed a bug with creating the prompt for a non-interactive search string
278 when there are non-printing characters in the primary prompt.
280 j. Fixed a bug that caused prompts with invisible characters to be redrawn
281 multiple times in a multibyte locale.
283 k. Fixed a bug that could cause the key sequence scanning code to return the
286 l. Fixed a problem with the callback interface that caused it to fail when
287 using multi-character keyboard macros.
289 m. Fixed a bug that could cause a core dump when an edited history entry was
290 re-executed under certain conditions.
292 n. Fixed a bug that caused readline to reference freed memory when attmpting
293 to display a portion of the prompt.
295 o. Fixed a bug with prompt redisplay in a multi-byte locale to avoid redrawing
296 the prompt and input line multiple times.
298 p. Fixed history expansion to not be confused by here-string redirection.
300 q. Readline no longer treats read errors by converting them to newlines, as
301 it does with EOF. This caused partial lines to be returned from readline().
303 r. Fixed a redisplay bug that occurred in multibyte-capable locales when the
304 prompt was one character longer than the screen width.
306 2. New Features in Readline
308 a. Calling applications can now set the keyboard timeout to 0, allowing
311 b. The value of SYS_INPUTRC (configurable at compilation time) is now used as
312 the default last-ditch startup file.
314 c. The history file reading functions now allow windows-like \r\n line
317 -------------------------------------------------------------------------------
318 This document details the changes between this version, readline-5.1,
319 and the previous version, readline-5.0.
321 1. Changes to Readline
323 a. Fixed a bug that caused multiliine prompts to be wrapped and displayed
326 b. Fixed a bug that caused ^P/^N in emacs mode to fail to display the current
329 c. Fixed a problem in computing the number of invisible characters on the first
330 line of a prompt whose length exceeds the screen width.
332 d. Fixed vi-mode searching so that failure preserves the current line rather
333 than the last line in the history list.
335 e. Fixed the vi-mode `~' command (change-case) to have the correct behavior at
336 end-of-line when manipulating multibyte characters.
338 f. Fixed the vi-mode `r' command (change-char) to have the correct behavior at
339 end-of-line when manipulating multibyte characters.
341 g. Fixed multiple bugs in the redisplay of multibyte characters: displaying
342 prompts longer than the screen width containing multibyte characters,
344 h. Fix the calculation of the number of physical characters in the prompt
345 string when it contains multibyte characters.
347 i. A non-zero value for the `rl_complete_suppress_append' variable now causes
348 no `/' to be appended to a directory name.
350 j. Fixed forward-word and backward-word to work when words contained
351 multibyte characters.
353 k. Fixed a bug in finding the delimiter of a `?' substring when performing
354 history expansion in a locale that supports multibyte characters.
356 l. Fixed a memory leak caused by not freeing the timestamp in a history entry.
358 m. Fixed a bug that caused "\M-x" style key bindings to not obey the setting
359 of the `convert-meta' variable.
361 n. Fixed saving and restoring primary prompt when prompting for incremental
362 and non-incremental searches; search prompts now display multibyte
363 characters correctly.
365 o. Fixed a bug that caused keys originally bound to self-insert but shadowed
366 by a multi-character key sequence to not be inserted.
368 p. Fixed code so rl_prep_term_function and rl_deprep_term_function aren't
369 dereferenced if NULL (matching the documentation).
371 q. Extensive changes to readline to add enough state so that commands
372 requiring additional characters (searches, multi-key sequences, numeric
373 arguments, commands requiring an additional specifier character like
374 vi-mode change-char, etc.) work without synchronously waiting for
377 r. Lots of changes so readline builds and runs on MinGW.
379 s. Readline no longer tries to modify the terminal settings when running in
382 t. The Readline display code no longer sets the location of the last invisible
383 character in the prompt if the \[\] sequence is empty.
385 u. The `change-case' command now correctly changes the case of multibyte
388 v. Changes to the shared library construction scripts to deal with Windows
389 DLL naming conventions for Cygwin.
391 w. Fixed the redisplay code to avoid core dumps resulting from a poorly-timed
394 x. Fixed the non-incremental search code in vi mode to dispose of any current
395 undo list when copying a line from the history into the current editing
398 y. Fixed a bug that caused reversing the incremental search direction to
401 z. Fixed the vi-mode `U' command to only undo up to the first time insert mode
402 was entered, as Posix specifies.
404 aa. Fixed a bug in the vi-mode `r' command that left the cursor in the wrong
407 bb. Fixed a redisplay bug caused by moving the cursor vertically to a line
408 with invisible characters in the prompt in a multibyte locale.
410 cc. Fixed a bug that could cause the terminal special chars to be bound in the
411 wrong keymap in vi mode.
413 2. New Features in Readline
415 a. The key sequence sent by the keypad `delete' key is now automatically
416 bound to delete-char.
418 b. A negative argument to menu-complete now cycles backward through the
421 c. A new bindable readline variable: bind-tty-special-chars. If non-zero,
422 readline will bind the terminal special characters to their readline
423 equivalents when it's called (on by default).
425 d. New bindable command: vi-rubout. Saves deleted text for possible
426 reinsertion, as with any vi-mode `text modification' command; `X' is bound
427 to this in vi command mode.
429 e. If the rl_completion_query_items is set to a value < 0, readline never
430 asks the user whether or not to view the possible completions.
432 f. The `C-w' binding in incremental search now understands multibyte
435 g. New application-callable auxiliary function, rl_variable_value, returns
436 a string corresponding to a readline variable's value.
438 h. When parsing inputrc files and variable binding commands, the parser
439 strips trailing whitespace from values assigned to boolean variables
440 before checking them.
442 i. A new external application-controllable variable that allows the LINES
443 and COLUMNS environment variables to set the window size regardless of
444 what the kernel returns.
446 -------------------------------------------------------------------------------
447 This document details the changes between this version, readline-5.0,
448 and the previous version, readline-4.3.
450 1. Changes to Readline
452 a. Fixes to avoid core dumps because of null pointer references in the
453 multibyte character code.
455 b. Fix to avoid infinite recursion caused by certain key combinations.
457 c. Fixed a bug that caused the vi-mode `last command' to be set incorrectly.
459 d. Readline no longer tries to read ahead more than one line of input, even
460 when more is available.
462 e. Fixed the code that adjusts the point to not mishandle null wide
465 f. Fixed a bug in the history expansion `g' modifier that caused it to skip
468 g. Fixed a bug that caused the prompt to overwrite previous output when the
469 output doesn't contain a newline and the locale supports multibyte
470 characters. This same change fixes the problem of readline redisplay
471 slowing down dramatically as the line gets longer in multibyte locales.
473 h. History traversal with arrow keys in vi insertion mode causes the cursor
474 to be placed at the end of the new line, like in emacs mode.
476 i. The locale initialization code does a better job of using the right
477 precedence and defaulting when checking the appropriate environment
480 j. Fixed the history word tokenizer to handle <( and >( better when used as
483 k. The overwrite mode code received several bug fixes to improve undo.
485 l. Many speedups to the multibyte character redisplay code.
487 m. The callback character reading interface should not hang waiting to read
490 n. Fixed a bug with redoing vi-mode `s' command.
492 o. The code that initializes the terminal tracks changes made to the terminal
493 special characters with stty(1) (or equivalent), so that these changes
494 are reflected in the readline bindings. New application-callable function
495 to make it work: rl_tty_unset_default_bindings().
497 p. Fixed a bug that could cause garbage to be inserted in the buffer when
498 changing character case in vi mode when using a multibyte locale.
500 q. Fixed a bug in the redisplay code that caused problems on systems
501 supporting multibyte characters when moving between history lines when the
502 new line has more glyphs but fewer bytes.
504 r. Undo and redo now work better after exiting vi insertion mode.
506 s. Make sure system calls are restarted after a SIGWINCH is received using
509 t. Improvements to the code that displays possible completions when using
510 multibyte characters.
512 u. Fixed a problem when parsing nested if statements in inputrc files.
514 v. The completer now takes multibyte characters into account when looking for
515 quoted substrings on which to perform completion.
517 w. The history search functions now perform better bounds checking on the
520 x. Change to history expansion functions to treat `^' as equivalent to word
521 one, as the documention states.
523 y. Some changes to the display code to improve display and redisplay of
524 multibyte characters.
526 z. Changes to speed up the multibyte character redisplay code.
528 aa. Fixed a bug in the vi-mode `E' command that caused it to skip over the
529 last character of a word if invoked while point was on the word's
530 next-to-last character.
532 bb. Fixed a bug that could cause incorrect filename quoting when
533 case-insensitive completion was enabled and the word being completed
534 contained backslashes quoting word break characters.
536 cc. Fixed a bug in redisplay triggered when the prompt string contains
537 invisible characters.
539 dd. Fixed some display (and other) bugs encountered in multibyte locales
540 when a non-ascii character was the last character on a line.
542 ee. Fixed some display bugs caused by multibyte characters in prompt strings.
544 ff. Fixed a problem with history expansion caused by non-whitespace characters
545 used as history word delimiters.
547 gg. Fixed a problem that could cause readline to refer to freed memory when
548 moving between history lines while doing searches.
550 hh. Improvements to the code that expands and displays prompt strings
551 containing multibyte characters.
553 ii. Fixed a problem with vi-mode not correctly remembering the numeric argument
554 to the last `c'hange command for later use with `.'.
556 jj. Fixed a bug in vi-mode that caused multi-digit count arguments to work
559 kk. Fixed a problem in vi-mode that caused the last text modification command
560 to not be remembered across different command lines.
562 ll. Fixed problems with changing characters and changing case at the end of
565 mm. Fixed a problem with readline saving the contents of the current line
566 before beginning a non-interactive search.
568 nn. Fixed a problem with EOF detection when using rl_event_hook.
570 oo. Fixed a problem with the vi mode `p' and `P' commands ignoring numeric
573 2. New Features in Readline
575 a. History expansion has a new `a' modifier equivalent to the `g' modifier
576 for compatibility with the BSD csh.
578 b. History expansion has a new `G' modifier equivalent to the BSD csh `g'
579 modifier, which performs a substitution once per word.
581 c. All non-incremental search operations may now undo the operation of
582 replacing the current line with the history line.
584 d. The text inserted by an `a' command in vi mode can be reinserted with
587 e. New bindable variable, `show-all-if-unmodified'. If set, the readline
588 completer will list possible completions immediately if there is more
589 than one completion and partial completion cannot be performed.
591 f. There is a new application-callable `free_history_entry()' function.
593 g. History list entries now contain timestamp information; the history file
594 functions know how to read and write timestamp information associated
597 h. Four new key binding functions have been added:
599 rl_bind_key_if_unbound()
600 rl_bind_key_if_unbound_in_map()
601 rl_bind_keyseq_if_unbound()
602 rl_bind_keyseq_if_unbound_in_map()
604 i. New application variable, rl_completion_quote_character, set to any
605 quote character readline finds before it calls the application completion
608 j. New application variable, rl_completion_suppress_quote, settable by an
609 application completion function. If set to non-zero, readline does not
610 attempt to append a closing quote to a completed word.
612 k. New application variable, rl_completion_found_quote, set to a non-zero
613 value if readline determines that the word to be completed is quoted.
614 Set before readline calls any application completion function.
616 l. New function hook, rl_completion_word_break_hook, called when readline
617 needs to break a line into words when completion is attempted. Allows
618 the word break characters to vary based on position in the line.
620 m. New bindable command: unix-filename-rubout. Does the same thing as
621 unix-word-rubout, but adds `/' to the set of word delimiters.
623 n. When listing completions, directories have a `/' appended if the
624 `mark-directories' option has been enabled.
626 -------------------------------------------------------------------------------
627 This document details the changes between this version, readline-4.3,
628 and the previous version, readline-4.2a.
630 1. Changes to Readline
632 a. Fixed output of comment-begin character when listing variable values.
634 b. Added some default key bindings for common escape sequences produced by
637 c. Fixed the mark handling code to be more emacs-compatible.
639 d. A bug was fixed in the code that prints possible completions to keep it
640 from printing empty strings in certain circumstances.
642 e. Change the key sequence printing code to print ESC as M\- if ESC is a
643 meta-prefix character -- it's easier for users to understand than \e.
645 f. Fixed unstifle_history() to return values that match the documentation.
647 g. Fixed the event loop (rl_event_hook) to handle the case where the input
648 file descriptor is invalidated.
650 h. Fixed the prompt display code to work better when the application has a
651 custom redisplay function.
653 i. Changes to make reading and writing the history file a little faster, and
654 to cope with huge history files without calling abort(3) from xmalloc.
656 j. The vi-mode `S' and `s' commands are now undone correctly.
658 k. Fixed a problem which caused the display to be messed up when the last
659 line of a multi-line prompt (possibly containing invisible characters)
660 was longer than the screen width.
662 2. New Features in Readline
664 a. Support for key `subsequences': allows, e.g., ESC and ESC-a to both
665 be bound to readline functions. Now the arrow keys may be used in vi
668 b. When listing completions, and the number of lines displayed is more than
669 the screen length, readline uses an internal pager to display the results.
670 This is controlled by the `page-completions' variable (default on).
672 c. New code to handle editing and displaying multibyte characters.
674 d. The behavior introduced in bash-2.05a of deciding whether or not to
675 append a slash to a completed name that is a symlink to a directory has
676 been made optional, controlled by the `mark-symlinked-directories'
677 variable (default is the 2.05a behavior).
679 e. The `insert-comment' command now acts as a toggle if given a numeric
680 argument: if the first characters on the line don't specify a
681 comment, insert one; if they do, delete the comment text
683 f. New application-settable completion variable:
684 rl_completion_mark_symlink_dirs, allows an application's completion
685 function to temporarily override the user's preference for appending
686 slashes to names which are symlinks to directories.
688 g. New function available to application completion functions:
689 rl_completion_mode, to tell how the completion function was invoked
690 and decide which argument to supply to rl_complete_internal (to list
693 h. Readline now has an overwrite mode, toggled by the `overwrite-mode'
694 bindable command, which could be bound to `Insert'.
696 i. New application-settable completion variable:
697 rl_completion_suppress_append, inhibits appending of
698 rl_completion_append_character to completed words.
700 j. New key bindings when reading an incremental search string: ^W yanks
701 the currently-matched word out of the current line into the search
702 string; ^Y yanks the rest of the current line into the search string,
703 DEL or ^H deletes characters from the search string.
705 -------------------------------------------------------------------------------
706 This document details the changes between this version, readline-4.2a,
707 and the previous version, readline-4.2.
709 1. Changes to Readline
711 a. More `const' and type casting fixes.
713 b. Changed rl_message() to use vsnprintf(3) (if available) to fix buffer
716 c. The completion code no longer appends a `/' or ` ' to a match when
717 completing a symbolic link that resolves to a directory name, unless
718 the match does not add anything to the word being completed. This
719 means that a tab will complete the word up to the full name, but not
720 add anything, and a subsequent tab will add a slash.
722 d. Fixed a trivial typo that made the vi-mode `dT' command not work.
724 e. Fixed the tty code so that ^S and ^Q can be inserted with rl_quoted_insert.
726 f. Fixed the tty code so that ^V works more than once.
728 g. Changed the use of __P((...)) for function prototypes to PARAMS((...))
729 because the use of __P in typedefs conflicted g++ and glibc.
731 h. The completion code now attempts to do a better job of preserving the
732 case of the word the user typed if ignoring case in completions.
734 i. Readline defaults to not echoing the input and lets the terminal
735 initialization code enable echoing if there is a controlling terminal.
737 j. The key binding code now processes only two hex digits after a `\x'
738 escape sequence, and the documentation was changed to note that the
739 octal and hex escape sequences result in an eight-bit value rather
742 k. Fixed a few places where negative array subscripts could have occurred.
744 l. Fixed the vi-mode code to use a better method to determine the bounds of
745 the array used to hold the marks, and to avoid out-of-bounds references.
747 m. Fixed the defines in chardefs.h to work better when chars are signed.
749 n. Fixed configure.in to use the new names for bash autoconf macros.
751 o. Readline no longer attempts to define its own versions of some ctype
752 macros if they are implemented as functions in libc but not as macros in
755 p. Fixed a problem where rl_backward could possibly set point to before
756 the beginning of the line.
758 q. Fixed Makefile to not put -I/usr/include into CFLAGS, since it can cause
759 include file problems.
761 2. New Features in Readline
763 a. Added extern declaration for rl_get_termcap to readline.h, making it a
764 public function (it was always there, just not in readline.h).
766 b. New #defines in readline.h: RL_READLINE_VERSION, currently 0x0402,
767 RL_VERSION_MAJOR, currently 4, and RL_VERSION_MINOR, currently 2.
769 c. New readline variable: rl_readline_version, mirrors RL_READLINE_VERSION.
771 d. New bindable boolean readline variable: match-hidden-files. Controls
772 completion of files beginning with a `.' (on Unix). Enabled by default.
774 e. The history expansion code now allows any character to terminate a
775 `:first-' modifier, like csh.
777 f. The incremental search code remembers the last search string and uses
778 it if ^R^R is typed without a search string.
780 h. New bindable variable `history-preserve-point'. If set, the history
781 code attempts to place the user at the same location on each history
782 line retrived with previous-history or next-history.
784 -------------------------------------------------------------------------------
785 This document details the changes between this version, readline-4.2,
786 and the previous version, readline-4.1.
788 1. Changes to Readline
790 a. When setting the terminal attributes on systems using `struct termio',
791 readline waits for output to drain before changing the attributes.
793 b. A fix was made to the history word tokenization code to avoid attempts to
794 dereference a null pointer.
796 c. Readline now defaults rl_terminal_name to $TERM if the calling application
797 has left it unset, and tries to initialize with the resultant value.
799 d. Instead of calling (*rl_getc_function)() directly to get input in certain
800 places, readline now calls rl_read_key() consistently.
802 e. Fixed a bug in the completion code that allowed a backslash to quote a
803 single quote inside a single-quoted string.
805 f. rl_prompt is no longer assigned directly from the argument to readline(),
806 but uses memory allocated by readline. This allows constant strings to
807 be passed to readline without problems arising when the prompt processing
808 code wants to modify the string.
810 g. Fixed a bug that caused non-interactive history searches to return the
811 wrong line when performing multiple searches backward for the same string.
813 h. Many variables, function arguments, and function return values are now
814 declared `const' where appropriate, to improve behavior when linking with
817 i. The control character detection code now works better on systems where
818 `char' is unsigned by default.
820 j. The vi-mode numeric argument is now capped at 999999, just like emacs mode.
822 k. The Function, CPFunction, CPPFunction, and VFunction typedefs have been
823 replaced with a set of specific prototyped typedefs, though they are
824 still in the readline header files for backwards compatibility.
826 m. Nearly all of the (undocumented) internal global variables in the library
827 now have an _rl_ prefix -- there were a number that did not, like
828 screenheight, screenwidth, alphabetic, etc.
830 n. The ding() convenience function has been renamed to rl_ding(), though the
831 old function is still defined for backwards compatibility.
833 o. The completion convenience functions filename_completion_function,
834 username_completion_function, and completion_matches now have an rl_
835 prefix, though the old names are still defined for backwards compatibility.
837 p. The functions shared by readline and bash (linkage is satisfied from bash
838 when compiling with bash, and internally otherwise) now have an sh_ prefix.
840 q. Changed the shared library creation procedure on Linux and BSD/OS 4.x so
841 that the `soname' contains only the major version number rather than the
842 major and minor numbers.
844 r. Fixed a redisplay bug that occurred when the prompt spanned more than one
845 physical line and contained invisible characters.
847 s. Added a missing `includedir' variable to the Makefile.
849 t. When installing the shared libraries, make sure symbolic links are relative.
851 u. Added configure test so that it can set `${MAKE}' appropriately.
853 v. Fixed a bug in rl_forward that could cause the point to be set to before
854 the beginning of the line in vi mode.
856 w. Fixed a bug in the callback read-char interface to make it work when a
857 readline function pushes some input onto the input stream with
858 rl_execute_next (like the incremental search functions).
860 x. Fixed a file descriptor leak in the history file manipulation code that
861 was tripped when attempting to truncate a non-regular file (like
864 y. Changes to make all of the exported readline functions declared in
865 readline.h have an rl_ prefix (rltty_set_default_bindings is now
866 rl_tty_set_default_bindings, crlf is now rl_crlf, etc.)
868 z. The formatted documentation included in the base readline distribution
869 is no longer removed on a `make distclean'.
871 aa. Some changes were made to avoid gcc warnings with -Wall.
873 bb. rl_get_keymap_by_name now finds keymaps case-insensitively, so
874 `set keymap EMACS' works.
876 cc. The history file writing and truncation functions now return a useful
879 dd. Fixed a bug that could cause applications to dereference a NULL pointer
880 if a NULL second argument was passed to history_expand().
882 ee. If a hook function assigned to rl_event_hook sets rl_done to a non-zero
883 value, rl_read_key() now immediately returns '\n' (which is assumed to
884 be bound to accept-line).
886 2. New Features in Readline
888 a. The blink timeout for paren matching is now settable by applications,
889 via the rl_set_paren_blink_timeout() function.
891 b. _rl_executing_macro has been renamed to rl_executing_macro, which means
892 it's now part of the public interface.
894 c. Readline has a new variable, rl_readline_state, which is a bitmap that
895 encapsulates the current state of the library; intended for use by
896 callbacks and hook functions.
898 d. rlfe has a new -l option to log input and output (-a appends to logfile),
899 a new -n option to set the readline application name, and -v and -h
900 options for version and help information.
902 e. rlfe can now perform filename completion for the inferior process if the
903 OS has a /proc/<PID>/cwd that can be read with readlink(2) to get the
904 inferior's current working directory.
906 f. A new file, rltypedefs.h, contains the new typedefs for function pointers
907 and is installed by `make install'.
909 g. New application-callable function rl_set_prompt(const char *prompt):
910 expands its prompt string argument and sets rl_prompt to the result.
912 h. New application-callable function rl_set_screen_size(int rows, int cols):
913 public method for applications to set readline's idea of the screen
916 i. The history example program (examples/histexamp.c) is now built as one
919 j. The documentation has been updated to cover nearly all of the public
920 functions and variables declared in readline.h.
922 k. New function, rl_get_screen_size (int *rows, int *columns), returns
923 readline's idea of the screen dimensions.
925 l. The timeout in rl_gather_tyi (readline keyboard input polling function)
926 is now settable via a function (rl_set_keyboard_input_timeout()).
928 m. Renamed the max_input_history variable to history_max_entries; the old
929 variable is maintained for backwards compatibility.
931 n. The list of characters that separate words for the history tokenizer is
932 now settable with a variable: history_word_delimiters. The default
935 o. There is a new history.3 manual page documenting the history library.
937 -------------------------------------------------------------------------------
938 This document details the changes between this version, readline-4.1,
939 and the previous version, readline-4.0.
941 1. Changes to Readline
943 a. Changed the HTML documents so that the table-of-contents is no longer
946 b. Changes to the shared object configuration for: Irix 5.x, Irix 6.x,
949 c. The shared library major and minor versions are now constructed
950 automatically by configure and substituted into the makefiles.
952 d. It's now possible to install the shared libraries separately from the
955 e. The history library tries to truncate the history file only if it is a
958 f. A bug that caused _rl_dispatch to address negative array indices on
959 systems with signed chars was fixed.
961 g. rl-yank-nth-arg now leaves the history position the same as when it was
964 h. Changes to the completion code to handle MS-DOS drive-letter:pathname
967 i. Completion is now case-insensitive by default on MS-DOS.
969 j. Fixes to the history file manipulation code for MS-DOS.
971 k. Readline attempts to bind the arrow keys to appropriate defaults on MS-DOS.
973 l. Some fixes were made to the redisplay code for better operation on MS-DOS.
975 m. The quoted-insert code will now insert tty special chars like ^C.
977 n. A bug was fixed that caused the display code to reference memory before
978 the start of the prompt string.
980 o. More support for __EMX__ (OS/2).
982 p. A bug was fixed in readline's signal handling that could cause infinite
983 recursion in signal handlers.
985 q. A bug was fixed that caused the point to be less than zero when rl_forward
986 was given a very large numeric argument.
988 r. The vi-mode code now gets characters via the application-settable value
989 of rl_getc_function rather than calling rl_getc directly.
991 s. The history file code now uses O_BINARY mode when reading and writing
992 the history file on cygwin32.
994 t. Fixed a bug in the redisplay code for lines with more than 256 line
997 u. A bug was fixed which caused invisible character markers to not be
998 stripped from the prompt string if the terminal was in no-echo mode.
1000 v. Readline no longer tries to get the variables it needs for redisplay
1001 from the termcap entry if the calling application has specified its
1002 own redisplay function. Readline treats the terminal as `dumb' in
1005 w. Fixes to the SIGWINCH code so that a multiple-line prompt with escape
1006 sequences is redrawn correctly.
1008 x. Changes to the install and install-shared targets so that the libraries
1009 and header files are installed separately.
1011 2. New Features in Readline
1013 a. A new Readline `user manual' is in doc/rluserman.texinfo.
1015 b. Parentheses matching is now always compiled into readline, and enabled
1016 or disabled when the value of the `blink-matching-paren' variable is
1019 c. MS-DOS systems now use ~/_inputrc as the last-ditch inputrc filename.
1021 d. MS-DOS systems now use ~/_history as the default history file.
1023 e. history-search-{forward,backward} now leave the point at the end of the
1024 line when the string to search for is empty, like
1025 {reverse,forward}-search-history.
1027 f. history-search-{forward,backward} now leave the last history line found
1028 in the readline buffer if the second or subsequent search fails.
1030 g. New function for use by applications: rl_on_new_line_with_prompt, used
1031 when an application displays the prompt itself before calling readline().
1033 h. New variable for use by applications: rl_already_prompted. An application
1034 that displays the prompt itself before calling readline() must set this to
1037 i. A new variable, rl_gnu_readline_p, always 1. The intent is that an
1038 application can verify whether or not it is linked with the `real'
1039 readline library or some substitute.
1041 j. Per Bothner's `rlfe' (pronounced `Ralphie') readline front-end program
1042 is included in the examples subdirectory, though it is not built
1045 -------------------------------------------------------------------------------
1046 This document details the changes between this version, readline-4.0,
1047 and the previous version, readline-2.2.
1049 1. Changes to Readline
1051 a. The version number is now 4.0, to match the major and minor version
1052 numbers on the shared readline and history libraries. Future
1053 releases will maintain the identical numbering.
1055 b. Fixed a typo in the `make install' recipe that copied libreadline.a
1056 to libhistory.old right after installing it.
1058 c. The readline and history info files are now installed out of the source
1059 directory if they are not found in the build directory.
1061 d. The library no longer exports a function named `savestring' -- backwards
1062 compatibility be damned.
1064 e. There is no longer any #ifdef SHELL code in the source files.
1066 f. Some changes were made to the key binding code to fix memory leaks and
1067 better support Win32 systems.
1069 g. Fixed a silly typo in the paren matching code -- it's microseconds, not
1072 h. The readline library should be compilable by C++ compilers.
1074 i. The readline.h public header file now includes function prototypes for
1075 all readline functions, and some changes were made to fix errors in the
1076 source files uncovered by the use of prototypes.
1078 j. The maximum numeric argument is now clamped at 1000000.
1080 k. Fixes to rl_yank_last_arg to make it behave better.
1082 l. Fixed a bug in the display code that caused core dumps if the prompt
1083 string length exceeded 1024 characters.
1085 m. The menu completion code was fixed to properly insert a single completion
1086 if there is only one match.
1088 n. A bug was fixed that caused the display code to improperly display tabs
1091 o. A fix was made to the completion code in which a typo caused the wrong
1092 value to be passed to the function that computed the longest common
1093 prefix of the list of matches.
1095 p. The completion code now checks the value of rl_filename_completion_desired,
1096 which is set by application-supplied completion functions to indicate
1097 that filename completion is being performed, to decide whether or not to
1098 call an application-supplied `ignore completions' function.
1100 q. Code was added to the history library to catch history substitutions
1101 using `&' without a previous history substitution or search having been
1105 2. New Features in Readline
1107 a. There is a new script, support/shobj-conf, to do system-specific shared
1108 object and library configuration. It generates variables for configure
1109 to substitute into makefiles. The README file provides a detailed
1110 explanation of the shared library creation process.
1112 b. Shared libraries and objects are now built in the `shlib' subdirectory.
1113 There is a shlib/Makefile.in to control the build process. `make shared'
1114 from the top-level directory is still the right way to build shared
1115 versions of the libraries.
1117 c. rlconf.h is now installed, so applications can find out which features
1118 have been compiled into the installed readline and history libraries.
1120 d. rlstdc.h is now an installed header file.
1122 e. Many changes to the signal handling:
1123 o Readline now catches SIGQUIT and cleans up the tty before returning;
1124 o A new variable, rl_catch_signals, is available to application writers
1125 to indicate to readline whether or not it should install its own
1126 signal handlers for SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP,
1127 SIGTTIN, and SIGTTOU;
1128 o A new variable, rl_catch_sigwinch, is available to application
1129 writers to indicate to readline whether or not it should install its
1130 own signal handler for SIGWINCH, which will chain to the calling
1131 applications's SIGWINCH handler, if one is installed;
1132 o There is a new function, rl_free_line_state, for application signal
1133 handlers to call to free up the state associated with the current
1134 line after receiving a signal;
1135 o There is a new function, rl_cleanup_after_signal, to clean up the
1136 display and terminal state after receiving a signal;
1137 o There is a new function, rl_reset_after_signal, to reinitialize the
1138 terminal and display state after an application signal handler
1139 returns and readline continues
1141 f. There is a new function, rl_resize_terminal, to reset readline's idea of
1142 the screen size after a SIGWINCH.
1144 g. New public functions: rl_save_prompt and rl_restore_prompt. These were
1145 previously private functions with a `_' prefix. These functions are
1146 used when an application wants to write a message to the `message area'
1147 with rl_message and have the prompt restored correctly when the message
1150 h. New function hook: rl_pre_input_hook, called just before readline starts
1151 reading input, after initialization.
1153 i. New function hook: rl_display_matches_hook, called when readline would
1154 display the list of completion matches. The new function
1155 rl_display_match_list is what readline uses internally, and is available
1156 for use by application functions called via this hook.
1158 j. New bindable function, delete-char-or-list, like tcsh.
1160 k. A new variable, rl_erase_empty_line, which, if set by an application using
1161 readline, will cause readline to erase, prompt and all, lines on which the
1162 only thing typed was a newline.
1164 l. There is a new script, support/shlib-install, to install and uninstall
1165 the shared readline and history libraries.
1167 m. A new bindable variable, `isearch-terminators', which is a string
1168 containing the set of characters that should terminate an incremental
1169 search without being executed as a command.
1171 n. A new bindable function, forward-backward-delete-char.
1173 -------------------------------------------------------------------------------
1174 This document details the changes between this version, readline-2.2,
1175 and the previous version, readline-2.1.
1177 1. Changes to Readline
1179 a. Added a missing `extern' to a declaration in readline.h that kept
1180 readline from compiling cleanly on some systems.
1182 b. The history file is now opened with mode 0600 when it is written for
1185 c. Changes were made to the SIGWINCH handling code so that prompt redisplay
1188 d. ^G now interrupts incremental searches correctly.
1190 e. A bug that caused a core dump when the set of characters to be quoted
1191 when completing words was empty was fixed.
1193 f. Fixed a problem in the readline test program rltest.c that caused a core
1196 g. The code that handles parser directives in inputrc files now displays
1197 more error messages.
1199 h. The history expansion code was fixed so that the appearance of the
1200 history comment character at the beginning of a word inhibits history
1201 expansion for that word and the rest of the input line.
1203 i. The code that prints completion listings now behaves better if one or
1204 more of the filenames contains non-printable characters.
1206 j. The time delay when showing matching parentheses is now 0.5 seconds.
1209 2. New Features in Readline
1211 a. There is now an option for `iterative' yank-last-arg handline, so a user
1212 can keep entering `M-.', yanking the last argument of successive history
1215 b. New variable, `print-completions-horizontally', which causes completion
1216 matches to be displayed across the screen (like `ls -x') rather than up
1217 and down the screen (like `ls').
1219 c. New variable, `completion-ignore-case', which causes filename completion
1220 and matching to be performed case-insensitively.
1222 d. There is a new bindable command, `magic-space', which causes history
1223 expansion to be performed on the current readline buffer and a space to
1224 be inserted into the result.
1226 e. There is a new bindable command, `menu-complete', which enables tcsh-like
1227 menu completion (successive executions of menu-complete insert a single
1228 completion match, cycling through the list of possible completions).
1230 f. There is a new bindable command, `paste-from-clipboard', for use on Win32
1231 systems, to insert the text from the Win32 clipboard into the editing
1234 g. The key sequence translation code now understands printf-style backslash
1235 escape sequences, including \NNN octal escapes. These escape sequences
1236 may be used in key sequence definitions or macro values.
1238 h. An `$include' inputrc file parser directive has been added.