Initializing interactive Python

qwweeeit at qwweeeit at
Sun Jul 24 12:26:06 CEST 2005

Hi all,
is it possible to enter an interactive session and automatically
do some initialization?
I explain better:
I want that when I start interactive Python on a console (I use Linux)
two command lines be executed automatically:

Python 2.3.4 (#2, Aug 19 2004, 15:49:40)
[GCC 3.4.1 (Mandrakelinux (Alpha 3.4.1-3mdk)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> x01=x02=0

I would like not to have to write anything at the prompt >>> to run
the two commands, but be ready to start the interactive session.

More information about the Python-list mailing list