Bug 56575 - .xlr is a application/vnd.ms-works Spreadsheet
Summary: .xlr is a application/vnd.ms-works Spreadsheet
Status: RESOLVED FIXED
Alias: None
Product: shared-mime-info
Classification: Unclassified
Component: freedesktop.org.xml (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Shared Mime Info group
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-30 08:59 UTC by Samuel Mehrbrodt
Modified: 2012-10-31 16:06 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Patch for xlr filetype (5.43 KB, patch)
2012-10-30 08:59 UTC, Samuel Mehrbrodt
Details | Splinter Review
don't we want it to be *application/vnd.ms-works* (5.45 KB, patch)
2012-10-30 12:28 UTC, Caolán McNamara
Details | Splinter Review

Description Samuel Mehrbrodt 2012-10-30 08:59:22 UTC
Created attachment 69296 [details] [review]
Patch for xlr filetype

.xlr was detected as 'application/x-ole-storage' and couldn't be assigned to the right application.
It is a MS-Works Spreadsheet file, see https://bugs.freedesktop.org/show_bug.cgi?id=45922 for more details.

Attached is a patch with the filetype and a testcase added.
Comment 1 Bastien Nocera 2012-10-30 09:38:09 UTC
You didn't test that patch though, did you?

test.xlr, 'name' test: expected application/application/vnd.ms-excel, got application/vnd.ms-excel
test.xlr, 'data' test: expected application/application/vnd.ms-excel, got application/x-ole-storage
test.xlr, 'file' test: expected application/application/vnd.ms-excel, got application/vnd.ms-excel
Comment 2 Bastien Nocera 2012-10-30 09:38:53 UTC
Even fixing the tests/list file I get:

test.xlr, 'data' test: expected application/vnd.ms-excel, got application/x-ole-storage
Comment 3 Samuel Mehrbrodt 2012-10-30 09:42:04 UTC
I changed the freedesktop.org.xml on my computer and after update-mime-database, mimetype tells me:
sam@3000-N100:~$ mimetype test.xlr 
test.xlr: application/vnd.ms-excel

I didn't test the test case though.
Comment 4 Samuel Mehrbrodt 2012-10-30 09:43:31 UTC
application/x-ole-storage is what it was before my changes.
Comment 5 Bastien Nocera 2012-10-30 09:52:30 UTC
(In reply to comment #3)
> I changed the freedesktop.org.xml on my computer and after
> update-mime-database, mimetype tells me:
> sam@3000-N100:~$ mimetype test.xlr 
> test.xlr: application/vnd.ms-excel
> 
> I didn't test the test case though.

Except that god knows what vendor patches your database has. Check the HACKING file on how to setup the test suite.
Comment 6 Caolán McNamara 2012-10-30 12:28:04 UTC
Created attachment 69301 [details] [review]
don't we want it to be *application/vnd.ms-works*

Don't we want this to be detected as application/vnd.ms-works rather than as excel. i.e. like this rework
Comment 7 Samuel Mehrbrodt 2012-10-30 14:57:17 UTC
How does LibreOffice then know that it should be opened with Calc?
Comment 8 Caolán McNamara 2012-10-30 16:22:55 UTC
ms-works filter apparently just outputs a writer or calc document depending on whether its a wps or xlr and libreoffice just "does the right thing"
Comment 9 Samuel Mehrbrodt 2012-10-30 16:52:53 UTC
Ok, thanks for helping out.
Did you test the new patch?
Comment 10 Caolán McNamara 2012-10-31 15:54:39 UTC
yeah, works for me (tm)
Comment 11 Bastien Nocera 2012-10-31 16:06:40 UTC
commit d3122c4234eff7dcf8fbbd6c8ae91a7c3203f17d
Author: Samuel Mehrbrodt <s.mehrbrodt@gmail.com>
Date:   Tue Oct 30 09:54:38 2012 +0100

    Added xlr filetype
    
    https://bugs.freedesktop.org/show_bug.cgi?id=56575


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.