confused about stdin
From: David Bear (david.bear_at_asu.edu)
Date: Thu, 21 Oct 2004 16:08:41 -0700
This may be a dumb question but I'm confused.
using command line syntax pipe like this:
cat somefile | pyscript
In my pyscript I can simply do
buffer = sys.stdin.read()
to get all of whatever cat sends.
However, using syntax like this:
pyscript < somefile
I'm not sure. Does this send to stdin as well?
And.. will it work on both unix and windows?
-- David Bear phone: 480-965-8257 fax: 480-965-9189 College of Public Programs/ASU Wilson Hall 232 Tempe, AZ 85287-0803 "Beware the IP portfolio, everyone will be suspect of trespassing"