From 4f81074ad4a0a308bfca9929c7ffbd69ea4a691c Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Thu, 2 Jun 2011 16:30:17 -0700 Subject: [PATCH] Add `file` tag for Mustache layouts For when you want to use something more descriptive than `title` in your layout. --- lib/rocco/layout.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/rocco/layout.rb b/lib/rocco/layout.rb index fa2b44c..5a9e988 100644 --- a/lib/rocco/layout.rb +++ b/lib/rocco/layout.rb @@ -15,6 +15,10 @@ class Rocco::Layout < Mustache File.basename(@doc.file) end + def file + @doc.file + end + def sections num = 0 @doc.sections.map do |docs,code|