Re: Suggestion for file type detection approach



On Fri, 2003-12-26 at 11:58, Adam Williams wrote:
> Why not support recording the mime-type of a file as meta-data (EA) on
> filesystems that support it (every one of them at this point?).  It
> would take awhile to be adopted by most/all GNOME apps but seems (IMHO)
> to clearly be the right way to do it.   If GNOME VFS supported it then
> it seems it would be easy to implement for alot of applications.
> 
> File extenstions are just DUMB and EASILY broken.  Sniffing is expensive
> and unreliable.

When is the EA set - when the file is created, or when the file is
modified? Who sets the EA? Can EA's be dated? The answers to these
questions are needed because:

     1. If applications need to set this new attribute when they create
        the file, then we would need to adapt a lot of programs. And if
        I use gedit on a shell script, what exactly is the resulting
        mimetype?
     2. If nautilus has to detect the filetype and set the attribute,
        you still retain all the inaccuracies of mimetype detection.
     3. If EAs are not updated by the application, we need dates so that
        it can be tested if the EA is up-to-date with respect to the
        file contents. If the EA is out-of-date, Nautilus would have to
        detect the filetype again.

Hope that someone gets something out of this email. :)

-- 
Peter Harvey.
Mostly Quiet.





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]