• Home
  • Raw
  • Download

Lines Matching refs:readline

1 :mod:`readline` --- GNU readline interface
4 .. module:: readline
6 :synopsis: GNU readline support for Python.
12 The :mod:`readline` module defines a number of functions to facilitate
22 <https://cnswww.cns.cwru.edu/php/chet/readline/rluserman.html#SEC9>`_
30 the ``libedit`` library instead of GNU readline.
31 On macOS the :mod:`readline` module detects which library is being used
35 of GNU readline. If you programmatically load configuration strings
36 you can check for the text "libedit" in :const:`readline.__doc__`
37 to differentiate between GNU readline and libedit.
39 If you use *editline*/``libedit`` readline emulation on macOS, the
62 Execute a readline initialization file. The default filename is the last filename
99 Load a readline history file, and append it to the history list.
106 Save the history list to a readline history file, overwriting any
181 input via readline. The *enabled* argument should be a Boolean value
202 arguments just before readline prints the first prompt.
212 readline starts reading input characters. This function only exists
223 the interactive interpreter. If the :mod:`readline` module is to be used
290 The following example demonstrates how to use the :mod:`readline` module's
298 import readline
302 readline.read_history_file(histfile)
304 readline.set_history_length(1000)
308 atexit.register(readline.write_history_file, histfile)
318 import readline
322 readline.read_history_file(histfile)
323 h_len = readline.get_current_history_length()
329 new_h_len = readline.get_current_history_length()
330 readline.set_history_length(1000)
331 readline.append_history_file(new_h_len - prev_h_len, histfile)
340 import readline
349 readline.parse_and_bind("tab: complete")
350 if hasattr(readline, "read_history_file"):
352 readline.read_history_file(histfile)
358 readline.set_history_length(1000)
359 readline.write_history_file(histfile)