diff --git a/lib/gollum/file_view.rb b/lib/gollum/file_view.rb index f0e3cf3c..a3072634 100644 --- a/lib/gollum/file_view.rb +++ b/lib/gollum/file_view.rb @@ -14,19 +14,20 @@ module Gollum end def new_page page - %Q(
  • #{page.name2}
  • \n) + name = page.name + %Q(
  • #{name}
  • \n) end def new_folder page - new_sub_folder ::File.dirname(page.path), page.name, page.name2 + new_sub_folder ::File.dirname(page.path), page.name end - def new_sub_folder path, name, name2 + def new_sub_folder path, name <<-HTML
    1. -
    2. #{name2}
    3. +
    4. #{name}
    5. HTML end @@ -63,12 +64,12 @@ module Gollum # Handle special case of only one folder. if (count - folder_start == 1) path = @pages[ folder_start ] - + name = page.name html += <<-HTML
      1. -
      2. #{page.name2}
      3. +
      4. #{name}
    6. HTML @@ -128,7 +129,7 @@ module Gollum end # subfolder - html += new_sub_folder ::File.dirname(page.path).split('/').last, page.name, page.name2 + html += new_sub_folder ::File.dirname(page.path).split('/').last, page.name else # depth+1 because we need an additional end_folder (depth+1).times { html += end_folder; } diff --git a/lib/gollum/page.rb b/lib/gollum/page.rb index 04b71974..6894ca2b 100644 --- a/lib/gollum/page.rb +++ b/lib/gollum/page.rb @@ -116,21 +116,14 @@ module Gollum self.class.strip_filename(filename) end - # Public: The canonical page name without extension. + # Public: The canonical page name without extension, and dashes converted + # to spaces. # # Returns the String name. def name self.class.canonicalize_filename(filename) end - # Public: The canonical page name without extension, and dashes - # really converted to spaces. - # - # Returns the String name. - def name2 - self.class.canonicalize_filename(filename).gsub('-', ' ') - end - # Public: The title will be constructed from the # filename by stripping the extension and replacing any dashes with # spaces.