Class: DtcRake::Config

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



13
14
15
16
17
18
19
20
# File 'lib/dtc_rake/config.rb', line 13

def initialize
  @root_dir   = Dir.pwd
  @output_dir = "target"
  @colorize   = true
  @appbox_meta_artifact_code = "UU.OS/RUNTIME/APP_BOX"
  @upload_app_descriptor = false
  guess_vendor_and_app
end

Instance Attribute Details

#appObject

Code of application. Guessed from root_dir name if not set.



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

def app
  @app
end

#app_descriptor_pathObject

Path to uuApp deployment descriptor. Guessed from vendor and app if not set.



44
45
46
# File 'lib/dtc_rake/config.rb', line 44

def app_descriptor_path
  @app_descriptor_path
end

#appbox_artifact_codeObject

Code of appbox artifact. Guessed from vendor, app and version in uuApp deployment descriptor if not set.



27
28
29
# File 'lib/dtc_rake/config.rb', line 27

def appbox_artifact_code
  @appbox_artifact_code
end

#appbox_location_codeObject

Code of appbox location (folder or organization unit). Required.



30
31
32
# File 'lib/dtc_rake/config.rb', line 30

def appbox_location_code
  @appbox_location_code
end

#appbox_meta_artifact_codeObject

Code of appbox meta artifact. Default value: UU.OS/RUNTIME/APP_BOX.



33
34
35
# File 'lib/dtc_rake/config.rb', line 33

def appbox_meta_artifact_code
  @appbox_meta_artifact_code
end

#appbox_territory_codeObject

Code of territory where the appbox artifact is / should be. Required.



36
37
38
# File 'lib/dtc_rake/config.rb', line 36

def appbox_territory_code
  @appbox_territory_code
end

#appbox_uarchiveObject

Path to uarchive with contents of appbox artifact. Default value: nil. If not set, appbox is created with empty content. Relative path is relative to root_dir.



41
42
43
# File 'lib/dtc_rake/config.rb', line 41

def appbox_uarchive
  @appbox_uarchive
end

#colorizeObject

Print messages in colors. Default value: true.



47
48
49
# File 'lib/dtc_rake/config.rb', line 47

def colorize
  @colorize
end

#output_dirObject

Name of folder with build products. Default value: target. Relative path is relative to root_dir.



51
52
53
# File 'lib/dtc_rake/config.rb', line 51

def output_dir
  @output_dir
end

#root_dirObject

Appbox project root folder. Default value: current working directory.



54
55
56
# File 'lib/dtc_rake/config.rb', line 54

def root_dir
  @root_dir
end

#upload_app_descriptorObject

Upload uuApp deployment descriptor to appbox artifact. Default value: false.



57
58
59
# File 'lib/dtc_rake/config.rb', line 57

def upload_app_descriptor
  @upload_app_descriptor
end

#vendorObject

Code of vendor. Guessed from root_dir name if not set.



60
61
62
# File 'lib/dtc_rake/config.rb', line 60

def vendor
  @vendor
end