GNOME Bugzilla – Bug 540000
Wrongly identifies LaTeX file as Matlab
Last modified: 2008-11-22 19:59:30 UTC
Please describe the problem: I always wondered why only my PDF files show up in searches but not my .tex files. Steps to reproduce: 1. First lines of .tex file are comments (symbol is %; similar to matlab) 2. Let it indexed with beagle-extract-content 3. "No filter for text/x-matlab" 3a. but "file" magic says "LaTeX 2e document text" Actual results: Expected results: If there is no parser for matlab, but there is one for LaTeX, please give LateX precedence. Does this happen every time? Other information: Example: % vi:fileencoding=latin1 \documentclass{acticle} \begin{document} \end{document}
Relatedly: If you say that this is possible I will open a new bug about it. Can we detect encoding from either the lines % vi:fileencoding=latin1 or \usepackage[latin1]{inputenc} My umlauts are garbled otherwise
Mimetype detection is done using the freedesktop.org specification and reference implementation shared-mime-info/xdgmime. That is beyond the scope of beagle. I am sorry. Detecting the encoding from the file is tricky but a valid bug. If you want, you can change the summary to "detecting file encoding of latex files". In that case, also attach a sample latex file which can be used for testing. Thanks.
No response in last several months. As explained in #2, the original problem in beyond our scope. Closing. If you want us to handle the secondary problem, please reopen and do as suggested in #2.