Gem Version Build Status Dependency Status Coverage Status Code Climate


The nanoc-toolbox is a collection of filters and helpers for the static site generator tool nanoc. I have created this gem for my personal need on my blog/resume website. If you feel something's missing, feel free to contribute.



  • Navigation: Menu, Breadcrumb, Table of contents,
  • Gravatar: Avatar Using the Gravatar System
  • HtmlTag: HTML Tag helper for other helpers
  • Google UA: Generate the JS code snipet for Universal Analytics
  • Google Analytics: Generate the JS code snipet for Analytics
  • Blogging Extra: Add extra blog post behavior
  • Tagging Extra: Add extra tagging behavior
  • Disqus: Disqus comments helper
  • Github Gist: Github Gist helper


  • AddSection: Section div's based on headers
  • HtmlTidy: Clean up the generated html code with Nokogiri
  • JS Minify: Minifies the JS files using JSMin

Requirements and compatibility

  • ruby >= 1.8.7: This gem has been tested against ruby 1.8.7 and 1.9.2
  • nanoc: It requires obviously the Nanoc gem
  • Nokogiri: For the HTML Tidy Filter
  • jsmin: For the JS Minify Filter


To use the nanoc-toolbox, you have to start by installing the gem.

gem install nanoc-toolbox

Then require the project main file in your default.rb file in the lib directory of your nanoc project.

require "nanoc/toolbox"

And the last step is to include the required helper or filter, anywhere in the lib directory of your lib directory. The usage wants you to put it in the default.rb or the helpers.rb file.

The following example shows a sample helpers_.rb file in the lib directory

# Default Helpers provided By Nanoc
include Nanoc3::Helpers::Blogging
include Nanoc3::Helpers::Breadcrumbs

# Custom Helpers
include Nanoc::Toolbox::Helpers::Navigation
include Nanoc::Toolbox::Helpers::Gravatar


API Documentation

The API documentation could be found on

Usage Guides

Some usage guides could be found on the GitHub wiki


All the people in this list



See the CHANGELOG file for details.


Copyright (c) 2011 Anouar ADLANI, nanoc-toolbox is released under the MIT license. See the LICENSE file for details.