Community Packages

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#55582 - [retext] conflicting mimetype data for markdown files

Attached to Project: Community Packages
Opened by deleteme (RASQ) - Monday, 11 September 2017, 07:06 GMT
Last edited by Jiachen Yang (farseerfc) - Tuesday, 13 November 2018, 17:17 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Jiachen Yang (farseerfc)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


In /usr/share/mime/packages, x-retext-markdown.xml contains mime data for markdown files that conflict with the data in This seems to give the rile a lower priority than the '## at offset 0' rule for MATLAB in, and prevents Dolphin (and possibly other programs?) from correctly identifying files using extensions that appear in both files if they begin with ##. The issue can be fixed by removing these lines from x-retext-markdown.xml:

<glob pattern="*.md"/>
<glob pattern="*.mkd"/>
<glob pattern="*.markdown"/>

these rules seem unnecessary because they also appear in

Additional info:
* package version - 7.0.1-1

Steps to reproduce:
With retext installed, create a file that begins with ## and save it with the extension '.md', '.mkd', or '.markdown'. View the file in Dolphin. It will be identified as MATLAB.
This task depends upon

Closed by  Jiachen Yang (farseerfc)
Tuesday, 13 November 2018, 17:17 GMT
Reason for closing:  Fixed
Additional comments about closing:  removed md definition from retext 7.0.4-3
Comment by Jiachen Yang (farseerfc) - Tuesday, 26 September 2017, 17:51 GMT
I don't quite understand what conflicts with what.
The rules provided in x-retext-markdown.xml file are meant to associate markdown files with retext as an editor.
While the rules in merely defines that they are markdown files, without specifying editors.

Following the "steps to reproduce", I noticed that the md file without "##" as a start will be correctly recognized as a md file and open with retext in dolphin.
While this behavior indeed is strange and needs more time to investigate, I have to point that any well-written markdown should not start with a h2 heading as "##" means in markdown.