Class: DevOops::ScriptsLoader::ScriptConfig
- Inherits:
-
Struct
- Object
- Struct
- DevOops::ScriptsLoader::ScriptConfig
- Defined in:
- lib/dev_oops/scripts_loader.rb
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
-
#desc ⇒ Object
Returns the value of attribute desc.
-
#dir ⇒ Object
Returns the value of attribute dir.
-
#name ⇒ Object
Returns the value of attribute name.
-
#script_location ⇒ Object
Returns the value of attribute script_location.
-
#usage ⇒ Object
Returns the value of attribute usage.
Class Method Summary collapse
Instance Attribute Details
#args ⇒ Object
Returns the value of attribute args
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def args @args end |
#desc ⇒ Object
Returns the value of attribute desc
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def desc @desc end |
#dir ⇒ Object
Returns the value of attribute dir
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def dir @dir end |
#name ⇒ Object
Returns the value of attribute name
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def name @name end |
#script_location ⇒ Object
Returns the value of attribute script_location
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def script_location @script_location end |
#usage ⇒ Object
Returns the value of attribute usage
6 7 8 |
# File 'lib/dev_oops/scripts_loader.rb', line 6 def usage @usage end |
Class Method Details
.create(script_name, script_location, json_config, dir) ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/dev_oops/scripts_loader.rb', line 8 def self.create(script_name, script_location, json_config, dir) new( script_name, json_config['desc'] || 'Missing description', "#{script_name} #{json_config['usage'] || ''}", script_location, json_config['args'], dir ) end |