gh-events 0.3.8 → 0.4.0

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: 712118f1c6b8f41b0d936d09e9b24a667e1cc9f51ab5534418adf8b4919ab47b
4
- data.tar.gz: ce35356926781a114738b40c29d7bc282478e5088cfd3383359ae2bae56d3622
3
+ metadata.gz: f5cf57e6ba3a08aafb7621eccddd5caa9d23dc2ef08a28946aed52a5d386349c
4
+ data.tar.gz: 60101c32e6d363aae13676305e8b3b79c3ec4780f7f9c0a38ad5551db628eac3
5
5
  SHA512:
6
- metadata.gz: 43d88aebdec1daceb51d1702f13bf4c841eab25d245e60d04d190108b58cbc63b671069a34de817c260beb0d1fe32ed3d5aa825c59e4fd73bf95fefef47223da
7
- data.tar.gz: ce143b305ba4f081c72947d9daf267f0104d88e49e0aa67a8746af971f86cec5bef70ab4acdea8fec8c0f3eaf6200a0685bc5d61150afbad0989f69368d000d6
6
+ metadata.gz: 7f2a72933f62af883eb804e78a1b1bf8578fb1f1d12447665968ffc4fe2f609ae46234004b8287014f2cc8648dcd0d66214a85bad23cf893ef3ecd47c1a24613
7
+ data.tar.gz: 472672fd5e5dae021d33b804bd82013fe0ef1ce78fa0c07c8f9fb3ed1a4093953eb0b26cebf5b5c77c43cc6c2b15f544461b66d4aa57fc2012eaeb087640c559
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gh-events (0.3.8)
4
+ gh-events (0.4.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -16,7 +16,8 @@ module GH::Events::Slack
16
16
  event.ref_type = 'tag' if event.ref&.match(/^refs\/tags\//)
17
17
  event.ref = event.ref&.split('/')&.last
18
18
 
19
- template = (templates[type] || "No template for type: #{type}.")
19
+ template = templates[[type, event.action]*'.']
20
+ template ||= (templates[type] || "No template for type: #{type}.")
20
21
  render(template, event)
21
22
  end
22
23
 
@@ -1,5 +1,5 @@
1
1
  module GH
2
2
  module Events
3
- VERSION = "0.3.8"
3
+ VERSION = "0.4.0"
4
4
  end
5
5
  end
data/res/slack.yml CHANGED
@@ -38,6 +38,13 @@ issues: >-
38
38
  <%= action %>
39
39
  issue <<%= issue.url %>|<%= issue.title %>>
40
40
  on <<%= repository.html_url %>|<%= repository.full_name %>>
41
+ <% if action == 'opened' %>| <%= issue.body %><% end %>
42
+
43
+ issues.labeled:
44
+ <<%= sender.html_url %>|<%= sender.login %>>
45
+ labeled
46
+ issue <<%= issue.url %>|<%= issue.title %>>
47
+ as `<%= label.name %>`
41
48
 
42
49
  pull_request: >-
43
50
  <<%= sender.html_url %>|<%= sender.login %>>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gh-events
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.8
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Phil Hofmann