By tag: nanoc

Nanoc on FLOSS weekly (TWIT)

Nanoc on FLOSS weekly episode 207 on the TWIT network. Aaron Newcomb and Dan Lynch interview Denis Defreyne from the Nanoc project. The show gives a good general run down on the capabilities of the system and how it compares to ot...

*

A simple Nanoc filter to compress HTML using Nokogiri

When using Nanoc, there are standard filter options for compressing CSS and minifying javascript, but there’s no equivalent for HTML. However, we can use Nokogiri to trim our HTML a little by removing some whitespace and getting rid of comments.

To do this, we’re going to build a custom Nanoc filter. Create a new file in lib/f...

*

Nanoc, Unicode and UTF-8

When using Nanoc, if you get weird characters in your HTML in place of some special characters or accented letters, you may well need to change your character encoding.

An example is ÔÇö instead of — (an em-dash).

First check your source file is in UTF-8. For example, you can use the Encode in UTF-8 without BOM ...

*