redirecting Stdin
Kristofer Wouk
kristofer at hotpop.com
Wed Dec 3 09:11:21 EST 2003
Jon Arter wrote:
> Hi
> Is is Possible to redirect the Python stdin in order to receive stdin
> commands from a file ?
> The time of redirection can last until exiting the Python and should
> be transparent for python it self.
>
> with regards
> Jon
>
>
>
>
If you're on *nix I know you can do this:
python myfile.py <somefile.txt
That would be transparent to your code.
Kris
More information about the Python-list
mailing list