tutter-sppuppet 1.2.7 → 1.2.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 +8 -8
- data/lib/tutter/action/sppuppet.rb +7 -0
- data/tutter-sppuppet.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
YjRjNWM2NzU3ODE1ZjdiYmY5Y2ExZTMzOGYwZTI0MjVlMWQwMTk4Yg==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MmFmNmE5ODgyY2EzZWUzNjY5MTJmZjgxMjk5MDNmMDM0OWYyMTEzNw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
OGM1YTE2OGFhNTczM2ExYTM3OWFiZWExZWMzYmM2Nzc4NTdhMzVlNjJlZjIx
|
10
|
+
NjQ5YTA4MTFmZTAzOWIwYmIwODc2Mzc5NzYwZmNlMDI5NzcyY2I0YmI4ODhl
|
11
|
+
ZDczYjc5ZTM5MTkxMzE4ZDlmNjFmZTNlZTNlNGM4NDNkNzk4NTU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
OTA3ZmE0OGY3MWQ0ZTE3NzNiODc5YTI4MDk0NjIwZjllZjgzMTUxMWUxMmYy
|
14
|
+
ZmQzY2E2Y2FiYjNhYmQzZDQzNjIzNjFmOTU3ZWMwZjY1MjA4MTNjMGVjMDQ1
|
15
|
+
ZDRhOThkMDAwYjM4ODhlNTk1ZTc0YTcyMTI3YWQ0Y2ViYWEzYjA=
|
@@ -4,6 +4,7 @@ require 'json'
|
|
4
4
|
class Sppuppet
|
5
5
|
# Match regexps
|
6
6
|
MERGE_COMMENT = /(:shipit:|:ship:|!merge)/
|
7
|
+
DELETE_BRANCH_COMMENT = /(:scissors:)/
|
7
8
|
PLUS_VOTE = /^(:?\+1:?|LGTM)/ # Match :+1:, +1, and LGTM
|
8
9
|
MINUS_VOTE = /^(:?\-1:?)/ # Match :-1: and -1
|
9
10
|
BLOCK_VOTE = /^(:poop:|:hankey:|-2)/ # Blocks merge
|
@@ -99,6 +100,10 @@ class Sppuppet
|
|
99
100
|
end
|
100
101
|
end
|
101
102
|
|
103
|
+
if DELETE_BRANCH_COMMENT.match(i.body)
|
104
|
+
@branch_to_delete = pr.head
|
105
|
+
end
|
106
|
+
|
102
107
|
if PLUS_VOTE.match(i.body) && pr.user.login != commenter
|
103
108
|
votes[commenter] = 1
|
104
109
|
if @settings['owners'].include?(commenter)
|
@@ -165,6 +170,8 @@ MERGE_MSG
|
|
165
170
|
end
|
166
171
|
begin
|
167
172
|
merge_commit = @client.merge_pull_request(@project, pull_request_id, merge_msg)
|
173
|
+
# If a owner posted a chop comment and was successfully merged delete the branch ref
|
174
|
+
@client.delete_branch(@project, @branch_to_delete) if @branch_to_delete
|
168
175
|
rescue Octokit::MethodNotAllowed => e
|
169
176
|
return post_comment(pull_request_id, "Pull request not mergeable: #{e.message}")
|
170
177
|
end
|
data/tutter-sppuppet.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
2
|
Gem::Specification.new do |s|
|
3
3
|
s.name = 'tutter-sppuppet'
|
4
|
-
s.version = '1.2.
|
4
|
+
s.version = '1.2.8'
|
5
5
|
s.author = ['Johan Haals', 'Erik Dalén', 'Alexey Lapitsky']
|
6
6
|
s.email = ['johan.haals@gmail.com', 'dalen@spotify.com', 'alexey@spotify.com']
|
7
7
|
s.homepage = 'https://github.com/jhaals/tutter-sppuppet'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tutter-sppuppet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Johan Haals
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-
|
13
|
+
date: 2016-04-28 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: tutter
|