Class: Typedeploy::Config

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/typedeploy/config.rb

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.api_tokenObject

Returns the value of attribute api_token.



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

def api_token
  @api_token
end

.directoryObject

Returns the value of attribute directory.



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

def directory
  @directory
end

.urlObject

Returns the value of attribute url.



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

def url
  @url
end

Class Method Details

.kitsObject



17
18
19
20
21
22
# File 'lib/typedeploy/config.rb', line 17

def self.kits
  kits = {}
  kits.default = ""
  kits.merge!(YAML.load(File.read(kits_file))) if File.exist? kits_file
  kits
end

.kits_directoryObject



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

def self.kits_directory
  File.join(directory, "kits")
end

.kits_fileObject



24
25
26
# File 'lib/typedeploy/config.rb', line 24

def self.kits_file
  File.join(directory, "kits.yml")
end