PYTHONSTARTUP ignored by python -i

Huaiyu Zhu hzhu at
Wed Sep 13 21:58:43 CEST 2000

Here's a simple thing that has bugged me for a while.

I want to do something like

python -i

and get the effect of 

>>> from file import *

However, it appears the .pythonrc in my $PYTHONSTARTUP is not read (which
does the readline, command completion and history recall stuff).

How do I achieve both results (.pythonrc and with one command line?

(No, cannot be put into .pythonrc because it is not used every time.
And no, cannot import .pythonrc because it is used by different
people in different environments.)


More information about the Python-list mailing list