Class: Awestruct::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/awestruct/config.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (Config) initialize(dir)

A new instance of Config



15
16
17
18
19
20
21
22
23
24
# File 'lib/awestruct/config.rb', line 15

def initialize(dir)
  @layouts_dir    = File.join(dir, '_layouts')
  @config_dir     = File.join(dir, '_config')
  @input_dir      = File.join(dir, '')
  @output_dir     = File.join(dir, '_site')
  @extension_dir  = File.join(dir, '_ext')
  @skin_dir       = File.join(dir, '_skin')
  @tmp_dir        = File.join(dir, '_tmp')
  @ignore         = File.exists?(ignore_file = File.join(dir, ".awestruct_ignore")) ? Dir[*IO.read(ignore_file).each_line.map(&:strip)] : []
end

Instance Attribute Details

- (Object) config_dir

Returns the value of attribute config_dir



7
8
9
# File 'lib/awestruct/config.rb', line 7

def config_dir
  @config_dir
end

- (Object) extension_dir

Returns the value of attribute extension_dir



8
9
10
# File 'lib/awestruct/config.rb', line 8

def extension_dir
  @extension_dir
end

- (Object) ignore

Returns the value of attribute ignore



13
14
15
# File 'lib/awestruct/config.rb', line 13

def ignore
  @ignore
end

- (Object) input_dir

Returns the value of attribute input_dir



9
10
11
# File 'lib/awestruct/config.rb', line 9

def input_dir
  @input_dir
end

- (Object) layouts_dir

Returns the value of attribute layouts_dir



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

def layouts_dir
  @layouts_dir
end

- (Object) output_dir

Returns the value of attribute output_dir



10
11
12
# File 'lib/awestruct/config.rb', line 10

def output_dir
  @output_dir
end

- (Object) skin_dir

Returns the value of attribute skin_dir



11
12
13
# File 'lib/awestruct/config.rb', line 11

def skin_dir
  @skin_dir
end

- (Object) tmp_dir

Returns the value of attribute tmp_dir



12
13
14
# File 'lib/awestruct/config.rb', line 12

def tmp_dir
  @tmp_dir
end