File: setup.rb

package info (click to toggle)
yard 0.9.37-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, trixie
  • size: 5,720 kB
  • sloc: ruby: 31,354; javascript: 7,608; makefile: 21
file content (25 lines) | stat: -rw-r--r-- 557 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# frozen_string_literal: true
include T('default/layout/html')

def init
  super

  @topfile = options.readme
  if options.files
    if @topfile
      @toptitle = @topfile.attributes[:title] || "Documentation Overview"
    end
    @page_title = @file == options.readme ? options.title : @file.title

    index = options.files.index(@file)
    if index
      @prevfile = index > 0 ? (options.files[index - 1] || options.readme) : nil
      @nextfile = options.files[index + 1]
    end
  end
end

def diskfile
  options.including_object = @object
  super
end