Hi,

>
> Boy, do I feel silly.  I've had to deal with CR-LF versus LF line-
> endings in text files for more years than I care to think about.  But
> I've also been using 'vi' (later 'vim' ) before PCs were made famous
> by Bill Gates.  However, somebody has 'improved' vi/vim now such that
> when I edited jallib.py and typed '1l' it didn't display the ^M like
> it should have (IMHO), and like it always has for years-- until
> recently?
>

I've never seen vim or vi displaying "\r" if file is *correctly* formatted.
But this is right I met PC after Bill Gates made them famous... By
"correctly formatted", I mean that if there's a mix with linefeed chars (eg.
"\n" and "\r\n") vim, guessing which is the one, will choose "\n" and thus
will display "\r" as part of the line content, not linefeed.

Also, it seems if "\r\n" is detected, vim will save it with "\r\n" too, even
if under *nix. You can force it with ":set fileformat=[unix,dos,max]". I've
found this page interesting: http://vim.wikia.com/wiki/File_format


> Thankfully, no one has 'improved' the trusty 'od -c jallib.py'
>

"od", cool, I wasn't aware of this tool !


> command, so I was able to see what you all suspected, and a quick
> 'dos2unix jallib.py' took care of the issue.
>
> Thanks for listening, and sorry to have wasted your time.
>
>
You're welcome, time not wasted :)


Cheers,
Seb

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/jallib?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to