Created: 2011-07-15 20:49
Updated: 2014-04-18 11:59



Rakepage is a tiny Rakefile that builds a static website from Markdown pages and static assets.

Be warned that this is one of those Works For Me (TM) projects -- it's my first contact with Ruby/Rake and I wrote it both to learn about the language(s) and because I thought it might make my life a bit easier. I use it to build a small, static website, and find it very useful.


Rakepage requires Ruby, Rake, and the Kramdown and Liquid gems. The auto mode depends on Watchr.


This could be the directory structure of a small Rakepage project:

|- Rakefile
|- site.yaml
|- layouts
    |- _default.liquid
    |- _footer.liquid
    |- _header.liquid
    |- ...
|- media
    |- css
        |- ...
    |- js
        |- ...
|- output
|- pages
    |- about.md
    |- contact.md
    |- index.md
    |- ...

Create the directory structure, then copy Rakefile and site.yaml into the project's root. Then create your pages, edit the configuration file, and when you're done...



(or rake gen) to convert all the Markdown pages into HTML, embed them in the Liquid layout and copy them and the static assets to output. Done!

While you are tweaking your site,

rake auto

is your friend: It simply triggers rake whenever a file changes on the disk -- normally the site is regenerated before you can press Alt-Tab and F5.


See site.yaml for all the configuration options.

-- curiousleo

Cookies help us deliver our services. By using our services, you agree to our use of cookies Learn more