[Tutor] Carriage return

Wayne srilyk at gmail.com
Mon Oct 12 05:38:10 CEST 2009

On Sun, Oct 11, 2009 at 10:33 PM, Vineet Kothari
<vineet.kothari at gmail.com>wrote:

> Hi Everyone
> I see that python IDLE add ^M as carriage return while programming in
> windows machine. How can I set IDLE not to do so. I don't see any option &
> neither do I see any option to check for carriage return.
> Can anyone help me as I use IDLE & I need to remove ^M from the end of
> every line. Though it is not shown while programming but I can see that when
> I run my scripts on debian linux environment & thus get errors.
That's not an issue with IDLE so much as windows/linux. IIRC, Linux only
uses a newline, while windows uses a CRLF. There's the dos2unix util:


that may help.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20091011/76efd96c/attachment.htm>

More information about the Tutor mailing list