SJS wrote:
begin quoting Ralph Shumaker as of Wed, Jan 23, 2008 at 10:05:58AM -0800:
Menachem Shapiro wrote:
[snip]
I wonder if it is a DOS vs UNIX line break issue. I don't use the
extension myself, but the documentation on the website seems to
indicate that you can have multiple line fortune cookies with text
based emails.
What happens if you change the formatting to a DOS line break?
[snip]>
I know that I've heard that there is an easy way to do that in vim, but
that was long before I could even use it. And my vim knowledge is quite
rudimentary. It occurred to me to try that, but didn't know how.
I suppose I could use KHexEdit to add ASCII 13, but don't know if it
goes before or after the ASCII 10. All in all, I think the vim
conversion would likely be easier.
Anyone care to tell me the vim magic for this?
To convert a *nix (LF) line ending to a DOS (CRLF) line ending?
If vim auto-detects the line ending style, you can change it, and
save, and you're done.
You can check the line-ending type by typing ":set ff", and you
can set it by giving an argument. So if you edit a file in vim,
and ":set ff" says "unix", you can type ":set ff=dos" and then
save the file... it will now have CRLF line endings.
Things get trickier when you mix line-ending styles in the same
file and vim guesses wrong.
Generally, using vi(m) to convert line-endings really only makes
sense when you're working with the file and notice that it's wonky.
If you already know the formats, well, that's what dos2unix and
unix2dos are for.
Thanks Stewart. I very much appreciate that you answered my question
*and* gave a better answer than what I asked for. :)
Unfortunately, as you can see, DOS formatted EOL does not fix the
problem. The DOS formatted EOL is stripped out just like the Unix
formatted EOL. :(
If I'm not mistaken, the bottom should look like:
--
Ralph
--------------------
line 1
line 2
line 3
--anon
--
Ralph -------------------- line 1 line 2 line 3 --anon
--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list