Class: Jigit::Jigitfile
- Inherits:
-
Object
- Object
- Jigit::Jigitfile
- Defined in:
- lib/jigit/core/jigitfile.rb
Instance Attribute Summary collapse
-
#host ⇒ String
JIRA server host.
-
#in_progress_status ⇒ String
The status which represens In Progress state.
-
#other_statuses ⇒ Array
The other possible statuses.
Instance Method Summary collapse
-
#initialize(path) ⇒ Jigitfile
constructor
A new instance of Jigitfile.
Constructor Details
#initialize(path) ⇒ Jigitfile
Returns a new instance of Jigitfile.
13 14 15 16 17 18 19 20 21 |
# File 'lib/jigit/core/jigitfile.rb', line 13 def initialize(path) raise "Path is a required parameter" if path.nil? raise "Couldn't find Jigitfile file at '#{path}'" unless File.exist?(path) jigitfile = File.read(path) yaml_hash = read_data_from_yaml_file(jigitfile, path) self.in_progress_status = yaml_hash[JigitfileConstants.in_progress_status] self.other_statuses = yaml_hash[JigitfileConstants.other_statuses] self.host = yaml_hash[JigitfileConstants.host] end |
Instance Attribute Details
#host ⇒ String
Returns JIRA server host.
11 12 13 |
# File 'lib/jigit/core/jigitfile.rb', line 11 def host @host end |
#in_progress_status ⇒ String
Returns The status which represens In Progress state.
7 8 9 |
# File 'lib/jigit/core/jigitfile.rb', line 7 def in_progress_status @in_progress_status end |
#other_statuses ⇒ Array
Returns The other possible statuses.
9 10 11 |
# File 'lib/jigit/core/jigitfile.rb', line 9 def other_statuses @other_statuses end |