Text Conversion

Bill Moran wmoran at iowna.com
Sun Oct 14 12:42:05 GMT 2001


If you look in the archives, this has been discussed in the past.
Personally, I think that doing this automagically is a Very Bad Idea (tm)
Look at it this way: what happens if you accidentally convert a binary
file because the user gave it a poor extension?  The data will be
corrupted and it may be difficult (read: likely impossible) to reverse
the process.
I still think that manually doing this as needed is the way to go.  The
way FTP does it is OK as well, since FTP has two very seperate modes and
you can easily turn the conversion on/off ... if there were a way to right
click on a share to turn CRLF conversion on/off, then it might be a good
idea, but that's not the case.

Joel Hammer wrote:
> 
> Samba doesn't do this for you.
> There is software out there that gives you drag and drop conversion from
> windows to linux/unix text formatting, and some of it is free.
> But, it is so easy to do, cat file | sed 's/\x0d$//', why bother?
> To go back, cat file | sed 's/^.*$/&\x0D/'
> This takes a newer version of sed.
> Joel
> 
> > Is there any way to get Samba to convert text files like FTP does? I
> > searched everywhere in the online documentation for a way to specify file
> > extensions to convert, but found nothing.
> >
> > If I drag and drop a text file from my Windows machine to a Samba share, I
> > would like Samba to convert the end-of-line characters to the Linux format.

-- 
"Where's the robot to pat you on the back?"




More information about the samba mailing list