Shebang line on Windows?
drobinow at gmail.com
Mon Feb 25 19:19:02 CET 2013
On Mon, Feb 25, 2013 at 12:29 PM, D'Arcy J.M. Cain <darcy at druid.net> wrote:
> I don't run Windows myself so I can't test it but doesn't Python on
> Windows work fine with Unix style EOL? So why not strip out the CR and
> run the same file everywhere?
That's the ideal solution, but so many Windows tools default to text
mode that it's easy to create the wrong type file, especially for
beginners who are moving there code to Linux for the first time. I've
done it myself, even though I should no better by now.
In addition, the error message is rather obscure (if I remember right
- I'm not near my Ubuntu at the moment and Cygwin handles this fine,
as it should)
I'm afraid this problem won't go away. People are just going to have
to learn from experience.
More information about the Python-list