ci_toolkit 1.5.5 → 1.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6d09aaba9d8cf3b06b0cf990f59346ebd0b60b461569a062f57eaee7343474b2
4
- data.tar.gz: 0f12abd8ebbb6abf38705c948d4c2f651413c918828b3008118a18cb1b7082de
3
+ metadata.gz: f11234ad0258930d676483a6489573cc85177c5436257785d9a9632709cd5bd5
4
+ data.tar.gz: e5d6284dbd20c33a4a4c272910cf583399f94eb5744fa1dba3bd7e9c67f133c6
5
5
  SHA512:
6
- metadata.gz: 404cd49f9ecd10a0959d540e13ff9bd2f40e2804af2949e1fc1f3b987eb68d51a841bb722baef9bfd60c05c3cdf4a7a6e988115d219fa276fab8a7409e253f66
7
- data.tar.gz: 522b89584b12430ae41f5a977ea3c1d0dae10c81d4be7e0fe561d3878cb03b2fa031a0007626f7df89e6efccefec755215344cbfb23f56e57e4d174a52c49f62
6
+ metadata.gz: bd3e440efc0fc2f7e8bc376f745ca1f2f6fba257f71d2b34b22c0e9d8c6fb1acce268ab902216f32e57fb70fa4f2ccb030a278583bbb4366cc9f6080512acb2d
7
+ data.tar.gz: 47c8697ab06e4fd4ad6c86cf08fb47b4605b2d9153a01de0c03cc26ece60d155eeadd4b6ec4d751a3f5f2d82d44d36a6c2af13dfc22db67b63de3d8ca7f92645
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ci_toolkit (1.5.5)
4
+ ci_toolkit (1.5.6)
5
5
  faraday
6
6
  faraday_middleware
7
7
  gitlab
@@ -27,14 +27,14 @@ module CiToolkit
27
27
  @github.create_status(state, @context, target_url, desc)
28
28
  end
29
29
 
30
- def increment
30
+ def increment(status = CiToolkit::DvcsPrUtil.status_state_pending)
31
31
  counter = load_counter
32
32
  return if counter.nil?
33
33
 
34
34
  num_finished = counter[:num_finished] + 1
35
35
  num_total = counter[:num_total]
36
36
 
37
- state = "pending"
37
+ state = status
38
38
  state = "success" if num_finished == num_total
39
39
 
40
40
  @github.create_status(state, @context, @env.app_url, "Finished building #{num_finished}/#{num_total}")
@@ -112,5 +112,11 @@ module CiToolkit
112
112
  status = "failed" if service == "gitlab"
113
113
  status
114
114
  end
115
+
116
+ def self.status_state_pending(service = ENV["DVCS_SERVICE"])
117
+ status = "pending"
118
+ status = "running" if service == "gitlab"
119
+ status
120
+ end
115
121
  end
116
122
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ci_toolkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.5
4
+ version: 1.5.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gero Keller