[NBLUG/talk] changeing line breaks.
Micxz
an_email at micxz.com
Sun Oct 19 18:12:01 PDT 2003
E Frank Ball wrote:
> On Sun, Oct 19, 2003 at 05:32:52PM -0700, Micxz wrote:
> }
> } In my small home network I have samba setup and I usually edit my files
> } in vi or from a pipe in my shell. Anyhow I want to know how I can
> } quickly on the command line edit the return characters so they will work
> } in windows for say notepad? My girlfriend looks at the files I created
> } an sees, "a little vertical standing rectangle" in place of every return
> } on newline in linux.
>
>
> I don't know what distribution you have but look for "todos" or
> "unix2dos". The inverse fucntions are "fromdos" and "dos2unix. On my
> debian machine there is only one binary, "fromdos" and the others are
> symlinks to it. see "man fromdos". The man page also calls it
> "tofrodos". RedHat seems to have "dos2unix" and "unix2dos".
>
I'm running suse 8.2 pro. But I don't seem to have "fromdos" or
"dos2unix", "unix2dos". Do you think I should try to install them on my
distro?
Do you know how the characters are represeted as? Like \n in linux is
what to windows?
Maybe I can sed it out like:
sed -e s/\\n/\\n\\windowbreak/g
And add whatever represents a windows return is replaced with the
"\windowsbreak" in the example above. Then it will work in both?
Maybe this is not possible?
--
Micxz
More information about the talk
mailing list