Class: Travis::Deploy::Config

Inherits:
Object
  • Object
show all
Includes:
Helper
Defined in:
lib/travis/deploy/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(shell, remote, options) ⇒ Config

Returns a new instance of Config.



11
12
13
14
15
16
# File 'lib/travis/deploy/config.rb', line 11

def initialize(shell, remote, options)
  @remote = remote
  @options = options
  @shell = shell
  @env = options['env'] || remote
end

Instance Attribute Details

#envObject (readonly)

Returns the value of attribute env.



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

def env
  @env
end

#optionsObject (readonly)

Returns the value of attribute options.



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

def options
  @options
end

#remoteObject (readonly)

Returns the value of attribute remote.



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

def remote
  @remote
end

#shellObject (readonly)

Returns the value of attribute shell.



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

def shell
  @shell
end

Instance Method Details

#invokeObject



18
19
20
21
# File 'lib/travis/deploy/config.rb', line 18

def invoke
  store unless options['source']
  push
end