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:
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.