ci_toolkit 1.2.7 → 1.3.8

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: f96e323d23cc03dde2298212e7a7366059bf64a3169d31d33f271ad5f161eb35
4
- data.tar.gz: d605aa63620d7612983d89ba762ad85edd43b50bbcb54912863284c1fa853891
3
+ metadata.gz: 49fe79e77eabec39109e46d51194950ec1d1aedaca71bbcbe3465f8a0bf75648
4
+ data.tar.gz: d9b33ac8738a40864565ec285ed5b2461f6d23aeb318e5ad188647e9a9ae7a03
5
5
  SHA512:
6
- metadata.gz: '0890d105a52a863159d3a0476ac8a16f71c306639e2c0b99aefb5ce5023679322783d3201529d9ff8dd085872d2c19a462cbcfb81b0496e79616642797f4549f'
7
- data.tar.gz: 2830123e7b171af70395c37b427f36fdfa33fac1f2d3d32bfee30d54a6ecc780671b6df5a38bc50d04f943da0f83f1f2d8e9536a68eea49ce69a56fc381d6001
6
+ metadata.gz: 02e7f0535cbc4a0c912ed764f6c11fb0c76a1c08b7b2ea70d16e6f1580fe9d4fc5bcebc68bc07e03175062180f7fe2981d5ca26ec947d004815689f713656e93
7
+ data.tar.gz: 57ba674797767d71e98c950e0f075a3b27905f402eb7d7a2a19515c87346f4dd9879a165180e27f20278bfb6d4148b77b614ce4e76f52c0e456b7e9b547d6dc1
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ci_toolkit (1.2.7)
4
+ ci_toolkit (1.3.8)
5
5
  faraday
6
6
  faraday_middleware
7
7
  jwt
@@ -39,7 +39,7 @@ GEM
39
39
  faraday_middleware (1.1.0)
40
40
  faraday (~> 1.0)
41
41
  json (2.5.1)
42
- jwt (2.2.3)
42
+ jwt (2.3.0)
43
43
  multipart-post (2.1.1)
44
44
  octokit (4.21.0)
45
45
  faraday (>= 0.9)
data/README.md CHANGED
@@ -17,10 +17,6 @@ Or install it yourself as:
17
17
 
18
18
  $ gem install ci_toolkit
19
19
 
20
- ## Usage
21
-
22
- TODO: Write usage instructions here
23
-
24
20
  ## Development
25
21
 
26
22
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec/test/test-unit` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -21,7 +21,6 @@ module CiToolkit
21
21
  @app_slug = options[:app_slug]
22
22
  @connection = faraday
23
23
  configure_connection
24
- @connection&.use Faraday::Response::Logger, nil, { headers: true, bodies: true }
25
24
  end
26
25
 
27
26
  def configure_connection
@@ -65,17 +64,12 @@ module CiToolkit
65
64
  pull_request_id: pull_request.to_i,
66
65
  status: 0 # status: 0 == not finished
67
66
  })
68
- puts "Response:\n"
69
- puts response.inspect
70
-
71
67
  builds = response.body["data"]
72
68
  filter_builds_by_commit(builds, commit)
73
69
  end
74
70
 
75
71
  def filter_builds_by_commit(builds, commit)
76
- puts "Builds:\n"
77
- puts builds.inspect
78
- builds&.select! { |build| build["commit_hash"] == commit || build["build_number"] == @build_number }
72
+ builds&.select! { |build| build["commit_hash"] == commit && build["build_number"] != @build_number }
79
73
  builds || []
80
74
  end
81
75
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CiToolkit
4
- VERSION = "1.2.7"
4
+ VERSION = "1.3.8"
5
5
  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.2.7
4
+ version: 1.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gero Keller
@@ -234,7 +234,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
234
234
  - !ruby/object:Gem::Version
235
235
  version: '0'
236
236
  requirements: []
237
- rubygems_version: 3.0.3
237
+ rubygems_version: 3.0.3.1
238
238
  signing_key:
239
239
  specification_version: 4
240
240
  summary: Set of CI utilities