Difference between revisions of "Nikola"

From WikEmacs
Jump to navigation Jump to search
(nikola and org workflow)
 
m (adding category)
Line 22: Line 22:
  
 
You can now write a blog post using orgmode and Nikola.
 
You can now write a blog post using orgmode and Nikola.
 +
 +
[[Category:Blog]]

Revision as of 10:49, 11 August 2014

Nikola is a static site generator, written in Python. It natively supports RestructuredText or Markdown, and it is also possible to write with orgmode thanks to a plugin.

Once you have setup your Nikola site, install the plugin with "nikola plugin -i orgmode" and add this in your config.py:

   # Add the orgmode compiler to your COMPILERS dict.
   COMPILERS["orgmode"] = ('.org',)
   # Add org files to your POSTS, PAGES
   POSTS = POSTS + (("posts/*.org", "posts", "post.tmpl"),)
   PAGES = PAGES + (("stories/*.org", "posts", "post.tmpl"),)

Now add Nikola's header in a comment block at the top of your new post:

   #+BEGIN_COMMENT 
   .. title: a title
   .. slug: a-title
   .. date: 2014-08-07 10:57:15 UTC-04:00 
   .. tags: one, two
   .. link: 
   .. description: 
   .. type: text 
   #+END_COMMENT

You can now write a blog post using orgmode and Nikola.