After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 331719 - latex docs beginning with comment (%) detected as MATLAB file
latex docs beginning with comment (%) detected as MATLAB file
Status: RESOLVED FIXED
Product: gnome-vfs
Classification: Deprecated
Component: MIME data
2.13.x
Other All
: Normal normal
: 2.14
Assigned To: Christian Neumair
gnome-vfs maintainers
Depends on:
Blocks:
 
 
Reported: 2006-02-18 23:02 UTC by Christian Kirbach
Modified: 2006-02-27 11:13 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
file demonstrating the problem (65 bytes, application/x-tex)
2006-02-18 23:05 UTC, Christian Kirbach
  Details
Patch that was committed to xdgmime (771 bytes, patch)
2006-02-19 12:43 UTC, Christian Neumair
none Details | Review
Patch that was committed to shared-mime-info (689 bytes, patch)
2006-02-19 12:44 UTC, Christian Neumair
none Details | Review

Description Christian Kirbach 2006-02-18 23:02:42 UTC
latex documents beginning with a comment (%) in the first line are detected as MATLAB script/function file
Comment 1 Christian Kirbach 2006-02-18 23:05:48 UTC
Created attachment 59672 [details]
file demonstrating the problem

open this file with gedit and notice the MIME type it detects (by hovering the tab with mouse pointer). Alternatively have nautilus show the file properties.

Note that gnomevfs-info seems to report this correctly
Comment 2 Luca Cavalli 2006-02-18 23:17:04 UTC
With gnome-vfs 2.12.2 the file is correctly identified as text/x-tex both by gnomevfs-info and gedit or nautilus.
Comment 3 Sebastien Bacher 2006-02-19 10:56:47 UTC
The type is "text/x-tex" on my Ubuntu installation, it works fine

Anyway the mimemagic definitions come from shared-mime-info which is a freedesktop component, closing as NOTGNOME
Comment 4 Christian Neumair 2006-02-19 12:17:16 UTC
Sorry, it was me who broke this. I've now added the "%" magic pattern to shared-mime-info for "text/x-tex", xdgmime has to be modified to use this, though.
Comment 5 Christian Neumair 2006-02-19 12:43:00 UTC
Created attachment 59704 [details] [review]
Patch that was committed to xdgmime

Feel free to apply it in gnome-vfs/src with a patchlevel of -p1.
Comment 6 Christian Neumair 2006-02-19 12:44:22 UTC
Created attachment 59706 [details] [review]
Patch that was committed to shared-mime-info

This one registeres the "%" matchlet for octave files.

After applying those two patches, both types are correctly recognized for me.
Comment 7 Christian Neumair 2006-02-19 12:46:33 UTC
Milestoning to 2.14.
Comment 8 Christian Neumair 2006-02-19 12:50:12 UTC
http://mail.gnome.org/archives/gnome-vfs-list/2006-February/msg00026.html contains the relevant commit request for gnome-vfs.
Comment 9 Christian Neumair 2006-02-27 11:13:28 UTC
The patch mentioned in comment 8 was and another patch [1] was committed, closing.

[1] http://mail.gnome.org/archives/gnome-vfs-list/2006-February/msg00077.html