How to set the history commands visible ?

Laura Creighton lac at openend.se
Sun Sep 13 16:15:52 EDT 2015


In a message of Sun, 13 Sep 2015 19:15:19 +0200, Glus Xof writes:
>Hi guys,
>
>Today, a new python stable version was released (thanks for your job)...
>and I write to ask you for the recommended method to compile the sources
>(in Debian GNU/Linux platfom) in order to the arrow keys emit the history
>commands instead of... it seems that escape sequences...
>
>Python 3.5.0 (default, Sep 13 2015, 17:58:38)
>[GCC 4.9.2] on linux
>Type "help", "copyright", "credits" or "license" for more information.
>>>> ^[[A^[[A^[[B^[[B
>
>(I run the configure, make, make test & make install scripts)

It seems your python is not installed with readline support, if
the arrow keys are not working.

You don't need to recompile python for this.
Instead you need to install this.
https://pypi.python.org/pypi/readline

But I am surprised that you need this, as my debian linux unstable
system has this out of the box, more or less always.

I think this is because I have this package installed
https://packages.debian.org/stretch/readline-common
(there are versions for testing and stable as well).

If I were you I would install this first and see if your
arrow problems go away.  If not, get out pip.

>Furthermore, I'd like also to ask a simple additional questions:
>
>Is yet an automatic indentation system implemented ?
>How to activate them ?

I am not sure what you mean by this.
If you, as I, was unhappy as anything about tab in the
interactive console (at the far margin) meaning 'tab complete
every builtin on the planet' rather than 'I'd like another level
of indent please' -- then, 3.5, you are good to go. :)  tabs typed
flush to the margin just indent.  tabs complete if you type them
in the middle of an identifier.

If you mean something else, then, well, explain it a little more, ok?


>Glus

Laura




More information about the Python-list mailing list