Command-line tool able to take multiple commands at one time?

Devan L devlai at gmail.com
Fri Nov 11 18:28:16 EST 2005


Peter A. Schott wrote:
> OK - I justed tested and may be doing something wrong, but it didn't work when I
> just tried it.
>
> I have something like this:
>
> X = "Value1"
> Y = "Value2"
> Z = "Value3"
>
> etc at the top of my script.  When I copy/paste those three lines all at once
> into IDLE's interactive window, X is defined, Y and Z are not.
>
> That's more the behaviour I was hoping for - the ability to run parts of my code
> at a time in order to work through issues without too much trouble in
> mostly-working code.
>
> TIA,
>
> -Pete Schott

Oh, that kind of multi-line input. I thought you were talking about
>>> def foo(bar):
...        long_statement_here
...        even_longer_statement_here
...        return something

I would just put it into a .py and run it through IDLE, change it, and
rerun it. There are probably other IDEs which can already do that, but
I just use IDLE.




More information about the Python-list mailing list