Persistent Python Command-Line History

前端 未结 5 738
灰色年华
灰色年华 2021-02-04 07:29

I\'d like to be able to \"up-arrow\" to commands that I input in a previous Python interpreter. I have found the readline module which offers functions like:

5条回答
  •  温柔的废话
    2021-02-04 08:18

    Try using IPython as a python shell. It already has everything you ask for. They have packages for most popular distros, so install should be very easy.

提交回复
热议问题