build-graph 2.0.2 → 2.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 85322b585449afb2106156d8a6b6c759e0b32a4b43f0b6f4788cb2b9d6d142dc
4
- data.tar.gz: 9f750c73fa57f33aa57b958b7d701af3fdb0df81b565eb3e4fbc3d04f17067aa
3
+ metadata.gz: cb877a85917d7de8c1d5a9bdc9d992188e8ab4268e567a0d5748186af65bc3bb
4
+ data.tar.gz: 8300948415d628e720da289156756b4b6cc18f383720e90cb397673df68a2abe
5
5
  SHA512:
6
- metadata.gz: 9b03a2d7ddb9031e1b2abaf49bccc05e6bb982cada8285d64c06aa80b2c0264e92ba55058f631740f2cbf3fe09cee94837cba79de401ef691ae108223e2c8aad
7
- data.tar.gz: 71015e73b6352cbc9e98a2db34a0700e7e59f5bd9335966a1f0a49749e79bcf570fce5827b1fa8e3a724893cca989f64875f6ab77871cd94ea8ddac1f2c120c5
6
+ metadata.gz: 0a51e3c3c19fb076cbaa2fdf2f5e7dea616d7c3d1d2434716723a4b2efb56315110098269d3c5e1c84d7b64dfa5244102bd150116d10a796e418073e11811963
7
+ data.tar.gz: fa7d7d72a74a1e631c3d72491aa6f67d1c0c884615f65a125822e3a6e32ba27ee6bd6069f5a16d540b75cfa85c125ccd982666f7e995b5f7708e6ec890d306fd
@@ -95,11 +95,9 @@ module Build
95
95
  fail!(InputsFailed)
96
96
  end
97
97
 
98
- if wait_for_children?
99
- update_outputs
100
- else
101
- fail!(ChildrenFailed)
102
- end
98
+ wait_for_children!
99
+
100
+ update_outputs!
103
101
 
104
102
  @state ||= :complete
105
103
 
@@ -156,7 +154,21 @@ module Build
156
154
  "#<#{self.class} #{node_string} #{state_string}>"
157
155
  end
158
156
 
159
- protected
157
+ def inspect
158
+ "\#<#{self.class}:0x#{self.object_id.to_s(16)} #{node_string} #{state_string}>"
159
+ end
160
+
161
+ protected
162
+
163
+ def wait_for_children!
164
+ unless wait_for_children?
165
+ fail!(ChildrenFailed)
166
+
167
+ return false
168
+ end
169
+
170
+ return true
171
+ end
160
172
 
161
173
  def state_string
162
174
  if @state
@@ -187,7 +199,7 @@ module Build
187
199
  end
188
200
 
189
201
  # If the node's outputs were a glob, this checks the filesystem to figure out what files were actually generated. If it inherits the outputs of the child tasks, merge them into our own outputs.
190
- def update_outputs
202
+ def update_outputs!
191
203
  if @node.inherit_outputs?
192
204
  @outputs = Files::State.new(self.children_outputs)
193
205
  else
@@ -20,6 +20,6 @@
20
20
 
21
21
  module Build
22
22
  module Graph
23
- VERSION = "2.0.2"
23
+ VERSION = "2.0.3"
24
24
  end
25
25
  end
@@ -237,6 +237,10 @@ module Build
237
237
  yield
238
238
  end
239
239
  end
240
+
241
+ def inspect
242
+ "\#<#{self.class}:0x#{self.object_id.to_s(16)} #{@tasks.count} tasks, #{@failed_tasks.count} failed>"
243
+ end
240
244
  end
241
245
  end
242
246
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: build-graph
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.2
4
+ version: 2.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -177,7 +177,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
177
177
  - !ruby/object:Gem::Version
178
178
  version: '0'
179
179
  requirements: []
180
- rubygems_version: 3.0.4
180
+ rubygems_version: 3.0.3
181
181
  signing_key:
182
182
  specification_version: 4
183
183
  summary: Build::Graph is a framework for build systems, with specific functionality