Class: Grifork::Config

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

Defined Under Namespace

Classes: Grifork, Log

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(args) ⇒ Config

Returns a new instance of Config.



5
6
7
8
9
# File 'lib/grifork/config.rb', line 5

def initialize(args)
  args.each do |key, val|
    instance_variable_set("@#{key}", val)
  end
end

Instance Attribute Details

#branchesObject (readonly)

Returns the value of attribute branches.



2
3
4
# File 'lib/grifork/config.rb', line 2

def branches
  @branches
end

#griforkObject (readonly)

Returns the value of attribute grifork.



2
3
4
# File 'lib/grifork/config.rb', line 2

def grifork
  @grifork
end

#griforkfileObject

Returns the value of attribute griforkfile.



3
4
5
# File 'lib/grifork/config.rb', line 3

def griforkfile
  @griforkfile
end

#hostsObject (readonly)

Returns the value of attribute hosts.



2
3
4
# File 'lib/grifork/config.rb', line 2

def hosts
  @hosts
end

#local_taskObject (readonly)

Returns the value of attribute local_task.



2
3
4
# File 'lib/grifork/config.rb', line 2

def local_task
  @local_task
end

#logObject (readonly)

Returns the value of attribute log.



2
3
4
# File 'lib/grifork/config.rb', line 2

def log
  @log
end

#remote_taskObject (readonly)

Returns the value of attribute remote_task.



2
3
4
# File 'lib/grifork/config.rb', line 2

def remote_task
  @remote_task
end

Instance Method Details

#modeObject



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

def mode
  @mode || :standalone
end