Some time ago I tried modifying pelican to work with emacs org mode files.
Somehow I got on the task again today - I think it was due to posts with embarrassingly poor formatting due to the limitations of the approach I used. Thankfully no one really reads this blog >_<.
It fixes the most significant to-dos from last time, which include
- no need for pandoc metadata templates
- now a plugin instead of in base pelican
It still has a couple issues. Tables do not get pretty styling. And I think there is a bug with pandoc where org mode file code blocks with header arguments somehow break syntax highlighting. Hopefully that gets an upstream fix, soon.
This version would also work much better for other people. Org and pelican are a fantastic duo!
class OrgPandocReader(BaseReader): enabled = True file_extensions = ['org'] def read(self, filename): with pelican_open(filename) as fp: text = list(fp.splitlines())
Images work but must be reference carefully (i.e. not using the strict org method)
# like this [[/images/2014-10-02-text-mining-my-org-agenda-files/unnamed-chunk-111.png]] # rather than, which gives inline image in org file [[file:images/2014-10-02-text-mining-my-org-agenda-files/unnamed-chunk-111.png]]