Readline on RedHat 7.1 with Python 2.1
Roman Suzi
rnd at onego.ru
Wed Jul 18 01:39:49 EDT 2001
On Tue, 17 Jul 2001, Kelly Gerber wrote:
> I am trying to build Python 2.1 on RedHat 7.1 with readline. I
> uncommented the readline line in Modules/Setup, but I get an error about
> readline when running make. Python builds and works fine otherwise. But
> it is a pain to type in commands again at the interactive prompt when I
> want to repeat something. Has any one had luck in getting Python to
> build with readline?
Isn't Python already compiled with readline in RH7.1???
If so, add
.startpy
import readline
import rlcompleter
readline.parse_and_bind("tab: complete")
print "Realine loaded"
to your homedir and put
export PYTHONSTARTUP=.startpy
into your .bash_profile
(if you are using bash)
Then re-login and try:
$ python
Readline loaded
>>> import os.
>>> os.
Display all 155 possibilities? (y or n)
as usual.
> Thanks,
> Kelly
Sincerely yours, Roman A.Suzi
--
- Petrozavodsk - Karelia - Russia - mailto:rnd at onego.ru -
More information about the Python-list
mailing list