Module: Danger::Toc::Config

Extended by:
Config
Included in:
Config
Defined in:
lib/toc/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#filesObject

Returns the value of attribute files.



6
7
8
# File 'lib/toc/config.rb', line 6

def files
  @files
end

#formatObject



19
20
21
# File 'lib/toc/config.rb', line 19

def format
  @format ||= default_format
end

#headerObject

Returns the value of attribute header.



6
7
8
# File 'lib/toc/config.rb', line 6

def header
  @header
end

Instance Method Details

#default_formatObject



23
24
25
# File 'lib/toc/config.rb', line 23

def default_format
  :github
end

#resetObject



27
28
29
30
31
# File 'lib/toc/config.rb', line 27

def reset
  self.files = ['README.md']
  self.header = 'Table of Contents'
  self.format = default_format
end