29 lines
560 B
Text
29 lines
560 B
Text
|
#!/usr/bin/env ruby
|
||
|
|
||
|
compile '/**/*.html' do
|
||
|
layout '/default.*'
|
||
|
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 :kramdown
|
||
|
# layout '/default.*'
|
||
|
#end
|
||
|
|
||
|
route '/**/*.{html,md}' do
|
||
|
if item.identifier =~ '/index.*'
|
||
|
'/index.html'
|
||
|
else
|
||
|
item.identifier.without_ext + '/index.html'
|
||
|
end
|
||
|
end
|
||
|
|
||
|
compile '/**/*' do
|
||
|
write item.identifier.to_s
|
||
|
end
|
||
|
|
||
|
layout '/**/*', :erb
|