gergich 0.1.1 → 0.1.2

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
  SHA1:
3
- metadata.gz: 5ce69d5f3767311808974507c74439d759b31bf2
4
- data.tar.gz: 93b1e7492252470f04c3d4c97bdd4ae75d1c7f83
3
+ metadata.gz: 63c9da0967fcb4d7728a748f1b64011e2fa03d02
4
+ data.tar.gz: 45e9c346faca8b021db278e2f6f96f32b9184b20
5
5
  SHA512:
6
- metadata.gz: 0661d29207244a62c42efa87a6fb9f6690ab5aaf93119ee343fcf0c569d1b331c2b5ea5232f39cef12cc1ef51b347616b2298ccc9993a936a92d68c7bb8b9a26
7
- data.tar.gz: e79ebdcd74b911f630e480acb97c73fe6b6770b45ff8d4321db087c43d0685238fa57f99c050829ec670ebb6330689ae9d4a2351388eedaf463bcfc7a25ece3c
6
+ metadata.gz: 170522d85e67ccb5293e3b4a797814abba906dd76eeb2769fa335b1723949bc73e22d922c44f32bb741e6d92f39b69ee90754b52b3dc7a7be7ffcbb049943579
7
+ data.tar.gz: ea79a99e4ffe01e6902908ffce696cd37843f67ac7fdf0449d6dc0eeaf91ec91147a1cfb2ab41428db2c450c8b101615c243c42a2114a37c7c3ff01e69e1dd04
data/lib/gergich.rb CHANGED
@@ -196,7 +196,7 @@ module Gergich
196
196
  end
197
197
  ret = HTTParty.send(method, url, options).body
198
198
  if ret.sub!(/\A\)\]\}'\n/, "") && ret =~ /\A("|\[|\{)/
199
- JSON.parse(ret)
199
+ JSON.parse("[#{ret}]")[0] # array hack so we can parse a string literal
200
200
  else
201
201
  raise("Non-JSON response: #{ret}")
202
202
  end
@@ -2,6 +2,7 @@ require_relative "../cli"
2
2
 
3
3
  ENV["GERGICH_USER"] = ENV.fetch("MASTER_BOUNCER_USER", "master_bouncer")
4
4
  ENV["GERGICH_KEY"] = ENV["MASTER_BOUNCER_KEY"] || error("no MASTER_BOUNCER_KEY set")
5
+ MASTER_BOUNCER_REVIEW_LABEL = ENV.fetch("GERGICH_REVIEW_LABEL", "Code-Review")
5
6
 
6
7
  require_relative "../../gergich"
7
8
 
@@ -51,7 +52,7 @@ def maybe_bounce_commit!(commit)
51
52
  # many times, so bail if nothing has changed
52
53
  return if score == previous_score
53
54
 
54
- draft.add_label "Code-Review", score
55
+ draft.add_label MASTER_BOUNCER_REVIEW_LABEL, score
55
56
  draft.add_message message if message
56
57
 
57
58
  # otherwise we always publish ... even in the score=0 case it's
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gergich
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jon Jensen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-21 00:00:00.000000000 Z
11
+ date: 2016-05-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sqlite3