【问题标题】:Configuring up and down arrows to scroll history in Python shell在 Python shell 中配置向上和向下箭头以滚动历史记录
【发布时间】:2010-11-09 02:25:04
【问题描述】:

我从源代码在我的 Mac 上安装了 Python 2.7。以前,我可以使用箭头键滚动浏览我的历史记录。现在,我明白了:

>>> print 'stupid'
'stupid'
>>> ^[[A # This is my feeble attempt at scrolling up.

如果我使用 Python 2.6,滚动仍然有效

是否有一个配置文件或者这是我必须在编译时设置的东西?

【问题讨论】:

    标签: python


    【解决方案1】:

    forgot 在构建之前安装 readline 或 libedit。

    【讨论】:

    • 啊,那行得通。 Homebrew 在编译 Python 时使用 readline。
    猜你喜欢
    • 2011-07-24
    • 1970-01-01
    • 2017-04-11
    • 1970-01-01
    • 1970-01-01
    • 2018-05-17
    • 2013-08-18
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多