I was disappointed to learn that GitHub flavored markdown does not support file inclusion, despite persistent requests for that feature.
So, I’ve put up a Ruby gem, markdown_helper, that implements file inclusion, as well as a couple of other features.
Class MarkdownHelper supports:
- File inclusion: to include text from other files, as code-block or markdown.
- Image path resolution: to resolve relative image paths to absolute URL paths (so they work even in gem documentation).
- Image attributes: image attributes are passed through to an HTML img tag.