34 lines
719 B
Text
34 lines
719 B
Text
|
#!/usr/bin/env ruby
|
||
|
|
||
|
compile '/**/*.html' do
|
||
|
filter :tufte
|
||
|
layout '/default.*'
|
||
|
|
||
|
if item.identifier =~ '**/index.*'
|
||
|
write item.identifier.to_s
|
||
|
else
|
||
|
write item.identifier.without_ext + '/index.html'
|
||
|
end
|
||
|
end
|
||
|
|
||
|
# This is an example rule that matches Markdown (.md) files, and filters them
|
||
|
# using the :kramdown filter. It is commented out by default, because kramdown
|
||
|
# is not bundled with Nanoc or Ruby.
|
||
|
#
|
||
|
compile '/**/*.md' do
|
||
|
filter :sidenotes
|
||
|
filter :kramdown
|
||
|
filter :tufte
|
||
|
layout '/default.*'
|
||
|
|
||
|
if item.identifier =~ '**/index.*'
|
||
|
write item.identifier.without_ext + '.html'
|
||
|
else
|
||
|
write item.identifier.without_ext + '/index.html'
|
||
|
end
|
||
|
end
|
||
|
|
||
|
passthrough '/**/*'
|
||
|
|
||
|
layout '/**/*', :erb
|