| 1 | This is a terse description of the new features added to readline-7.0 since |
| 2 | the release of readline-6.3. |
| 3 | |
| 4 | New Features in Readline |
| 5 | |
| 6 | a. The history truncation code now uses the same error recovery mechansim as |
| 7 | the history writing code, and restores the old version of the history file |
| 8 | on error. The error recovery mechanism handles symlinked history files. |
| 9 | |
| 10 | b. There is a new bindable variable, `enable-bracketed-paste', which enables |
| 11 | support for a terminal's bracketed paste mode. |
| 12 | |
| 13 | c. The editing mode indicators can now be strings and are user-settable |
| 14 | (new `emacs-mode-string', `vi-cmd-mode-string' and `vi-ins-mode-string' |
| 15 | variables). Mode strings can contain invisible character sequences. |
| 16 | Setting mode strings to null strings restores the defaults. |
| 17 | |
| 18 | d. Prompt expansion adds the mode string to the last line of a multi-line |
| 19 | prompt (one with embedded newlines). |
| 20 | |
| 21 | e. There is a new bindable variable, `colored-completion-prefix', which, if |
| 22 | set, causes the common prefix of a set of possible completions to be |
| 23 | displayed in color. |
| 24 | |
| 25 | f. There is a new bindable command `vi-yank-pop', a vi-mode version of emacs- |
| 26 | mode yank-pop. |
| 27 | |
| 28 | g. The redisplay code underwent several efficiency improvements for multibyte |
| 29 | locales. |
| 30 | |
| 31 | h. The insert-char function attempts to batch-insert all pending typeahead |
| 32 | that maps to self-insert, as long as it is coming from the terminal. |
| 33 | |
| 34 | i. rl_callback_sigcleanup: a new application function that can clean up and |
| 35 | unset any state set by readline's callback mode. Intended to be used |
| 36 | after a signal. |
| 37 | |
| 38 | ------------------------------------------------------------------------------- |
| 39 | This is a terse description of the new features added to readline-6.3 since |
| 40 | the release of readline-6.2. |
| 41 | |
| 42 | New Features in Readline |
| 43 | |
| 44 | a. Readline is now more responsive to SIGHUP and other fatal signals when |
| 45 | reading input from the terminal or performing word completion but no |
| 46 | longer attempts to run any not-allowable functions from a signal handler |
| 47 | context. |
| 48 | |
| 49 | b. There are new bindable commands to search the history for the string of |
| 50 | characters between the beginning of the line and the point |
| 51 | (history-substring-search-forward, history-substring-search-backward) |
| 52 | |
| 53 | c. Readline allows quoted strings as the values of variables when setting |
| 54 | them with `set'. As a side effect, trailing spaces and tabs are ignored |
| 55 | when setting a string variable's value. |
| 56 | |
| 57 | d. The history library creates a backup of the history file when writing it |
| 58 | and restores the backup on a write error. |
| 59 | |
| 60 | e. New application-settable variable: rl_filename_stat_hook: a function called |
| 61 | with a filename before using it in a call to stat(2). Bash uses it to |
| 62 | expand shell variables so things like $HOME/Downloads have a slash |
| 63 | appended. |
| 64 | |
| 65 | f. New bindable function `print-last-kbd-macro', prints the most-recently- |
| 66 | defined keyboard macro in a reusable format. |
| 67 | |
| 68 | g. New user-settable variable `colored-stats', enables use of colored text |
| 69 | to denote file types when displaying possible completions (colored analog |
| 70 | of visible-stats). |
| 71 | |
| 72 | h. New user-settable variable `keyseq-timout', acts as an inter-character |
| 73 | timeout when reading input or incremental search strings. |
| 74 | |
| 75 | i. New application-callable function: rl_clear_history. Clears the history list |
| 76 | and frees all readline-associated private data. |
| 77 | |
| 78 | j. New user-settable variable, show-mode-in-prompt, adds a characters to the |
| 79 | beginning of the prompt indicating the current editing mode. |
| 80 | |
| 81 | k. New application-settable variable: rl_input_available_hook; function to be |
| 82 | called when readline detects there is data available on its input file |
| 83 | descriptor. |
| 84 | |
| 85 | l. Readline calls an application-set event hook (rl_event_hook) after it gets |
| 86 | a signal while reading input (read returns -1/EINTR but readline does not |
| 87 | handle the signal immediately) to allow the application to handle or |
| 88 | otherwise note it. |
| 89 | |
| 90 | m. If the user-settable variable `history-size' is set to a value less than |
| 91 | 0, the history list size is unlimited. |
| 92 | |
| 93 | n. New application-settable variable: rl_signal_event_hook; function that is |
| 94 | called when readline is reading terminal input and read(2) is interrupted |
| 95 | by a signal. Currently not called for SIGHUP or SIGTERM. |
| 96 | |
| 97 | ------------------------------------------------------------------------------- |
| 98 | This is a terse description of the new features added to readline-6.1 since |
| 99 | the release of readline-6.0. |
| 100 | |
| 101 | New Features in Readline |
| 102 | |
| 103 | a. New bindable function: menu-complete-backward. |
| 104 | |
| 105 | b. In the vi insertion keymap, C-n is now bound to menu-complete by default, |
| 106 | and C-p to menu-complete-backward. |
| 107 | |
| 108 | c. When in vi command mode, repeatedly hitting ESC now does nothing, even |
| 109 | when ESC introduces a bound key sequence. This is closer to how |
| 110 | historical vi behaves. |
| 111 | |
| 112 | d. New bindable function: skip-csi-sequence. Can be used as a default to |
| 113 | consume key sequences generated by keys like Home and End without having |
| 114 | to bind all keys. |
| 115 | |
| 116 | e. New application-settable function: rl_filename_rewrite_hook. Can be used |
| 117 | to rewite or modify filenames read from the file system before they are |
| 118 | compared to the word to be completed. |
| 119 | |
| 120 | f. New bindable variable: skip-completed-text, active when completing in the |
| 121 | middle of a word. If enabled, it means that characters in the completion |
| 122 | that match characters in the remainder of the word are "skipped" rather |
| 123 | than inserted into the line. |
| 124 | |
| 125 | g. The pre-readline-6.0 version of menu completion is available as |
| 126 | "old-menu-complete" for users who do not like the readline-6.0 version. |
| 127 | |
| 128 | h. New bindable variable: echo-control-characters. If enabled, and the |
| 129 | tty ECHOCTL bit is set, controls the echoing of characters corresponding |
| 130 | to keyboard-generated signals. |
| 131 | |
| 132 | i. New bindable variable: enable-meta-key. Controls whether or not readline |
| 133 | sends the smm/rmm sequences if the terminal indicates it has a meta key |
| 134 | that enables eight-bit characters. |
| 135 | |
| 136 | ------------------------------------------------------------------------------- |
| 137 | This is a terse description of the new features added to readline-6.0 since |
| 138 | the release of readline-5.2. |
| 139 | |
| 140 | New Features in Readline |
| 141 | |
| 142 | a. A new variable, rl_sort_completion_matches; allows applications to inhibit |
| 143 | match list sorting (but beware: some things don't work right if |
| 144 | applications do this). |
| 145 | |
| 146 | b. A new variable, rl_completion_invoking_key; allows applications to discover |
| 147 | the key that invoked rl_complete or rl_menu_complete. |
| 148 | |
| 149 | c. The functions rl_block_sigint and rl_release_sigint are now public and |
| 150 | available to calling applications who want to protect critical sections |
| 151 | (like redisplay). |
| 152 | |
| 153 | d. The functions rl_save_state and rl_restore_state are now public and |
| 154 | available to calling applications; documented rest of readline's state |
| 155 | flag values. |
| 156 | |
| 157 | e. A new user-settable variable, `history-size', allows setting the maximum |
| 158 | number of entries in the history list. |
| 159 | |
| 160 | f. There is a new implementation of menu completion, with several improvements |
| 161 | over the old; the most notable improvement is a better `completions |
| 162 | browsing' mode. |
| 163 | |
| 164 | g. The menu completion code now uses the rl_menu_completion_entry_function |
| 165 | variable, allowing applications to provide their own menu completion |
| 166 | generators. |
| 167 | |
| 168 | h. There is support for replacing a prefix of a pathname with a `...' when |
| 169 | displaying possible completions. This is controllable by setting the |
| 170 | `completion-prefix-display-length' variable. Matches with a common prefix |
| 171 | longer than this value have the common prefix replaced with `...'. |
| 172 | |
| 173 | i. There is a new `revert-all-at-newline' variable. If enabled, readline will |
| 174 | undo all outstanding changes to all history lines when `accept-line' is |
| 175 | executed. |
| 176 | |
| 177 | ------------------------------------------------------------------------------- |
| 178 | This is a terse description of the new features added to readline-5.2 since |
| 179 | the release of readline-5.1. |
| 180 | |
| 181 | New Features in Readline |
| 182 | |
| 183 | a. Calling applications can now set the keyboard timeout to 0, allowing |
| 184 | poll-like behavior. |
| 185 | |
| 186 | b. The value of SYS_INPUTRC (configurable at compilation time) is now used as |
| 187 | the default last-ditch startup file. |
| 188 | |
| 189 | c. The history file reading functions now allow windows-like \r\n line |
| 190 | terminators. |
| 191 | |
| 192 | ------------------------------------------------------------------------------- |
| 193 | This is a terse description of the new features added to readline-5.1 since |
| 194 | the release of readline-5.0. |
| 195 | |
| 196 | New Features in Readline |
| 197 | |
| 198 | a. The key sequence sent by the keypad `delete' key is now automatically |
| 199 | bound to delete-char. |
| 200 | |
| 201 | b. A negative argument to menu-complete now cycles backward through the |
| 202 | completion list. |
| 203 | |
| 204 | c. A new bindable readline variable: bind-tty-special-chars. If non-zero, |
| 205 | readline will bind the terminal special characters to their readline |
| 206 | equivalents when it's called (on by default). |
| 207 | |
| 208 | d. New bindable command: vi-rubout. Saves deleted text for possible |
| 209 | reinsertion, as with any vi-mode `text modification' command; `X' is bound |
| 210 | to this in vi command mode. |
| 211 | |
| 212 | e. If the rl_completion_query_items is set to a value < 0, readline never |
| 213 | asks the user whether or not to view the possible completions. |
| 214 | |
| 215 | f. New application-callable auxiliary function, rl_variable_value, returns |
| 216 | a string corresponding to a readline variable's value. |
| 217 | |
| 218 | g. When parsing inputrc files and variable binding commands, the parser |
| 219 | strips trailing whitespace from values assigned to boolean variables |
| 220 | before checking them. |
| 221 | |
| 222 | h. A new external application-controllable variable that allows the LINES |
| 223 | and COLUMNS environment variables to set the window size regardless of |
| 224 | what the kernel returns. |
| 225 | |
| 226 | |
| 227 | ------------------------------------------------------------------------------- |
| 228 | This is a terse description of the new features added to readline-5.0 since |
| 229 | the release of readline-4.3. |
| 230 | |
| 231 | New Features in Readline |
| 232 | |
| 233 | a. History expansion has a new `a' modifier equivalent to the `g' modifier |
| 234 | for compatibility with the BSD csh. |
| 235 | |
| 236 | b. History expansion has a new `G' modifier equivalent to the BSD csh `g' |
| 237 | modifier, which performs a substitution once per word. |
| 238 | |
| 239 | c. All non-incremental search operations may now undo the operation of |
| 240 | replacing the current line with the history line. |
| 241 | |
| 242 | d. The text inserted by an `a' command in vi mode can be reinserted with |
| 243 | `.'. |
| 244 | |
| 245 | e. New bindable variable, `show-all-if-unmodified'. If set, the readline |
| 246 | completer will list possible completions immediately if there is more |
| 247 | than one completion and partial completion cannot be performed. |
| 248 | |
| 249 | f. There is a new application-callable `free_history_entry()' function. |
| 250 | |
| 251 | g. History list entries now contain timestamp information; the history file |
| 252 | functions know how to read and write timestamp information associated |
| 253 | with each entry. |
| 254 | |
| 255 | h. Four new key binding functions have been added: |
| 256 | |
| 257 | rl_bind_key_if_unbound() |
| 258 | rl_bind_key_if_unbound_in_map() |
| 259 | rl_bind_keyseq_if_unbound() |
| 260 | rl_bind_keyseq_if_unbound_in_map() |
| 261 | |
| 262 | i. New application variable, rl_completion_quote_character, set to any |
| 263 | quote character readline finds before it calls the application completion |
| 264 | function. |
| 265 | |
| 266 | j. New application variable, rl_completion_suppress_quote, settable by an |
| 267 | application completion function. If set to non-zero, readline does not |
| 268 | attempt to append a closing quote to a completed word. |
| 269 | |
| 270 | k. New application variable, rl_completion_found_quote, set to a non-zero |
| 271 | value if readline determines that the word to be completed is quoted. |
| 272 | Set before readline calls any application completion function. |
| 273 | |
| 274 | l. New function hook, rl_completion_word_break_hook, called when readline |
| 275 | needs to break a line into words when completion is attempted. Allows |
| 276 | the word break characters to vary based on position in the line. |
| 277 | |
| 278 | m. New bindable command: unix-filename-rubout. Does the same thing as |
| 279 | unix-word-rubout, but adds `/' to the set of word delimiters. |
| 280 | |
| 281 | n. When listing completions, directories have a `/' appended if the |
| 282 | `mark-directories' option has been enabled. |