Ticket 31216 / Python libedit

Chris Perl chris.perl at gmail.com
Thu Nov 10 05:12:20 PST 2011


As per [1], it appears that all version of python were recently
switched to using libedit instead of readline.  As a pretty heavy user of
the python interacitve interpreter this has caused me some issues.

By default, it appears that a bunch of the readline emacs bindings I use
on a daily basis are not bound.  For example:

  "M-B"  backward-word
  "M-F"  forward-word
  "M-D"  kill-word
  "C-_"  undo

I've been reading EDITRC(5) and trying to get a workable .editrc that
mimics the readline functionality I'm used to, but its not going so
well.  Some things like undo just don't seem to do what I'm expecting
them to do.

I'm sure if I put enough effort in, I could figure out some kind of
workable solution.  However, what I really want is a consistent line
editing environment between my shell of choice (bash) and the python
interactive interpreter.

How about the idea of adding a "readline" variant to python to allow it
to build against readline instead of libedit?


Chris

1.  https://svn.macports.org/ticket/31216



More information about the macports-dev mailing list