Re: Nautilus, metadata and extendet attributes



On Mon, 2004-02-02 at 16:08, Manuel Amador (Rudd-O) wrote:

> 
> The point is that encoding file type information in the file name is
> wrong.  To a big extent, files already "know" which file type are
> themselves, the problem is that the file manager is slow in determining
> file types because it has to sniff.

It seems to me:
It is not true that files "know" which file type they are.

// Suppose I write a poem
// and for visual effect
// I begin each line with //
// Is this a C++ program?

Or, to take an even more extreme example, an empty file is a special
case of any language which allows an empty production of the root symbol
e.g. program -> [statement;] - therefore can legitimately be one of
many filetypes.

To recognise every filetype by sniffing you need to code the syntax
specification of every computer language! Sniffing is in principle NOT
the answer, it is only the system's guess as to what you mean; that
guess is often not right, and the system can NEVER have a complete
list of filetypes and heuristics - new file types are created every day.
So, the problem of sniffing is NOT just implementation (speed), it has
serious problems of principle. The file type cannot be automatically
determined by sniffing file contents, it is truly METAdata which is
non-redundant, i.e. not deducible from the file contents. To put it
simply, it is a tag set by the user to say "this is my preferred
application for opening this file". In practice it will usually be
set by the application which creates the file, but it may be necessary
for an advanced user to override it sometimes.

Thus, the EA idea seems to me to be the right way to go.
Where sniffing comes in handy is in identifying files which do not
already have an associated
mime-type attribute, that is files which have been transferred over
the internet, say, from a machine which does not have the EA support
or which is not "trusted" (i.e. most machines, I guess).

The attacks in this thread on the traditional use of file extensions are
I think excessively strong. Before the advent of filesystems with EAs,
using a reserved field within the filename was a perfectly logical
(though limited) alternative way of storing this kind of metadata...

Just my 2p,

Peter Wainwright

> 
> Extensions are just a hack, not a proper file type specification.  The
> current status quo is, therefore, a hack.  Unknowing users will always
> trample on that hack in the most unexpected way.  I myself have intended
> to rename files and kill the extension in the process.   That's exactly
> why Windows Explorer hides extensions by default.  And if Nautilus goes
> that route to avoid "user stupidity" (which is actually programmer
> stupidity) we'll end up with the same situation as with Windows
> Explorer.
> 
> Besides, it's about time I should be able to have OpenOffice files on my
> folders that don't have an extension, yet they open properly when I
> double-click them.  Get the point?
> 
> > Please please please... tell us !
-- 
Peter Wainwright <prw ceiriog1 demon co uk>



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