slackit 1.1.5 → 1.1.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: fc2b364ceeb787f7bc47fbe8cf678747c19f2ed0842291e7db06254a73747e84
4
- data.tar.gz: 38180076c8f3d9e53fb7e259b03a8e4cef149d5469211a0745c54e656b516394
3
+ metadata.gz: 97ef94b287628f23c968e9147de986212f36ffb42b2ba50fcddf34ad212f9cd9
4
+ data.tar.gz: 7d20d5251f98dc09eeb20af0e8109cc9b804395d22ec7b4ecd2c1e71e39b865a
5
5
  SHA512:
6
- metadata.gz: c84f78c9e09559a7aac8df9fa1fecc4203655f0cecaa856059176014ced2aa78429b231d8c4bf8c7d6cb6cb8245ccfa009ff05452320939133de574ed3b9607a
7
- data.tar.gz: dd617efc328490d668aa3a912bffc2e1ab0544843da92e79008a0eae6db82cccb74519a678c25d5c99e9600ad0f2b7f8f520044220a695c6e2d32d2e248ecf20
6
+ metadata.gz: 9dc3f2a5c00fb15787218cbfa9e9686349b9e74f7e38066066e4cf7ae3971c1fb11d8c08f778c6fa308e201ea4cd9bcb242849f239a1a3fd40eadc6e0a269558
7
+ data.tar.gz: 0647742f03103c4102aa198a00367c2a449cd02447dadb08d55cc76fe3efd2dda3583a658983893b72873119a09e9cfca56c24d94be3aeff77f753783d4b48ec
data/CHANGELOG.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  IMPROVEMENTS:
4
4
 
5
- * Clean up tweaks based on updaes to rubocop. ([@TGWolf][])
5
+ * Clean up tweaks based on updates to rubocop. ([@TGWolf][])
6
6
 
7
7
  ## 1.1.4 (March 13, 2019)
8
8
 
data/exe/slackit CHANGED
@@ -11,7 +11,8 @@ require 'slackit'
11
11
 
12
12
  def send_message_to_slack(options)
13
13
  begin
14
- s = Slackit.new(webhook_url: options[:webhook_url], channel: options[:channel], username: options[:username], icon_emoji: options[:icon_emoji])
14
+ # s = Slackit.new(webhook_url: options[:webhook_url], channel: options[:channel], username: options[:username], icon_emoji: options[:icon_emoji])
15
+ s = Slackit.new(options)
15
16
  s.send(options[:message])
16
17
  rescue ArgumentError
17
18
  puts "You must specify a webhook_url"
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class Slackit
4
- VERSION = '1.1.5'
4
+ VERSION = '1.1.6'
5
5
  end
data/lib/slackit.rb CHANGED
@@ -26,8 +26,8 @@ class Slackit
26
26
  text = text.gsub('\\n', "\n") # ensure newlines are not escaped
27
27
  body = { 'text' => text, 'icon_emoji' => @icon_emoji, 'username' => @username }
28
28
 
29
- # add the channel if there is one otherwise the default channel
30
- body['channel'] = @channel || '#general'
29
+ # add the channel if there is one
30
+ body['channel'] ||= @channel
31
31
 
32
32
  begin
33
33
  response = HTTParty.post(@webhook_url, body: body.to_json, headers: headers)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slackit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.5
4
+ version: 1.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tim Gurney aka Wolf
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-06-28 00:00:00.000000000 Z
11
+ date: 2019-09-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler