class TreeDecorator

Public Instance Methods

breadcrumbs(max_links = 2) { |link_to("..", "| ... } click to toggle source
readme() click to toggle source
# File app/decorators/tree_decorator.rb, line 32
def readme
  @readme ||= contents.find { |c| c.is_a?(Grit::Blob) and c.name =~ %r^readme/ }
end
up_dir?() click to toggle source
# File app/decorators/tree_decorator.rb, line 23
def up_dir?
  path.present?
end
up_dir_path() click to toggle source
# File app/decorators/tree_decorator.rb, line 27
def up_dir_path
  file = File.join(path, "..")
  h.project_tree_path(project, h.tree_join(ref, file))
end