#12141 closed defect (fixed)
INSTALL.rst not rendered as RestructuredText
Reported by: | Ryan J Ollos | Owned by: | Ryan J Ollos |
---|---|---|---|
Priority: | normal | Milestone: | 1.2 |
Component: | rendering | Version: | |
Severity: | normal | Keywords: | pygments |
Cc: | Branch: | ||
Release Notes: |
Renamed |
||
API Changes: | |||
Internal Changes: |
Description
One of the tasks in #12120 is to add the rst
extension to INSTALL
and UPGRADE
. However, INSTALL.rst
is rendered in plain text due to the default value of [mimeview]
mime_map_patterns
.
[mimeviewer]
mime_map_patterns | List of additional MIME types associated to filename patterns. Mappings are comma-separated, and each mapping consists of a MIME type and a Python regexp used for matching filenames, separated by a colon (":"). (since 1.0) | text/plain:README(?!\.rst)|INSTALL(?!\.rst)|COPYING.* |
Another issue is that both UPGRADE.rst
and INSTALL.rst
(after correcting above issue) are rendered with mimetype text/prs.fallenstein.rst
. The issue may only occur when Pygments is installed. More investigation is needed.
Attachments (0)
Change History (6)
comment:1 by , 9 years ago
Milestone: | next-dev-1.1.x → 1.2 |
---|---|
Owner: | set to |
Status: | new → assigned |
comment:2 by , 9 years ago
comment:3 by , 9 years ago
Release Notes: | modified (diff) |
---|
Proposed changes in log:rjollos.git:t12141_install_rst_rendering. I considered an upgrade step to modify the trac.ini for existing users, but I tend to think it's not worth the complication or effort.
DONE Modify TracDev/ReleaseChecklist#Wikirelatedfiles to change output filenames.
DONE Modify [mimeviewer] mime_map_patterns
in the trac.ini for t.e.o.
comment:4 by , 9 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Committed to trunk in [14330].
comment:5 by , 9 years ago
This hint led me to consider if we should add the rst
extension to README
and RELEASE
, since both are written in ReST. Proposed changes in log:rjollos.git:t12141_more_rst_rendering.
Replying to Ryan J Ollos:
With Pygments installed we just get Syntax Highlighting. Rendering to HTML requires Docutils installed.
When Pygments is installed the
mime_map
is populated by get_extra_mimetype from Pygments. Pygments returns the mapping'rst': 'text/x-rst'
followed by'rst': 'text/prs.fallenstein.rst'
, with the latter overwriting the former in the dictionary. This doesn't seem to be a problem since prs.fallenstein.rst appears to be an alias oftext/x-rst
.