On 2 October 2015 at 11:06, Edward d'Auvergne <true.bug...@gmail.com> wrote: > Hi all, > > I was wondering if this should be considered a bug. At the FlightGear > project we have a 6 GB data svn repository for aircraft ( > https://sourceforge.net/projects/flightgear/ , > https://sourceforge.net/p/flightgear/fgaddon/HEAD/tree/ ). A large > quantity of the files, almost 30,000 in number, are XML text files. > > The problem is that modern Subversion clients appear to all be using > libmagic to determine the file type, to then set the svn:mime-type > property. However this is rather problematic: > > $ file -ib Aircraft/747-400/747-400-set.xml > application/xml; charset=us-ascii > > Libmagic detects all these XML files as "application/xml". Hence they > are treated as binary files! There are many other text files with > extensions such as *.ac, *.nas, etc. present in the repository that in > the future might be detected by libmagic as "application/xyz". > Easy fix would be change svn_mime_type_is_binary() to consider 'application/xml' as text file. We can also extend for other specific application/* mimetypes that are text files. We already have special handling for 'image/x-xbitmap' to consider it as text file.
Does it make sense? -- Ivan Zhakov