say2slack 0.0.3 → 0.0.6

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: d699c370fb05ecb927c38d0dc672cb9e7f35543d
4
- data.tar.gz: 2f189cc277e25ec452aebaea301c303a5d9fc183
3
+ metadata.gz: 2c3360302806cd423a2b8d8ff2fb9c0361850775
4
+ data.tar.gz: 8a8348fdb0b5a6279447c2bcf1f525498f333631
5
5
  SHA512:
6
- metadata.gz: 7ee4e81fd4ac3aec26f80b22ae83b5f4bc59ef677f1d2360f9ea5db7ca6b25234c0542125060fc92f304e3b1553038dfc250fb8e2635f523bce8a276a4a3b8fd
7
- data.tar.gz: 1c05d613f570f04d445ddca2086bfc951a1109b81a454dbffd4b5fed0cbf0da29c5dda06749e962f7d81b57e751aa1c20bb0d7dc37b51a4c79324da3ae98e62c
6
+ metadata.gz: ce90aa241d75b87c58ef6cb86ff86073f2c038dfa238c05d2b544bcfca88e96c77988abf0c41c1cbe44b872f98cd0dba92becd887686fb659fedbb020480d809
7
+ data.tar.gz: 983e1529046b8e28cbfe0b6553233134b310c47cf48620ab7c32764412d7cbcb84cdbd95763097dd92b890d04462a3cbce22c255650201cadb4c35d5069f223c
data/README.md CHANGED
@@ -26,6 +26,6 @@ Set environment variables for:
26
26
 
27
27
  Call from your code:
28
28
 
29
- `"FromName".says("Message").to("#roomName")`
29
+ `"FromName".says("Message").to_channel("#roomName")`
30
30
 
31
31
  where FromName is who you want the message to be sent from, Message is the text you want posted to the channel, and roomName is the name of the channel you're posting to. roomName can also be a @user. In this instance, it appear in the slackbot thread.
@@ -4,7 +4,7 @@ module Say2Slack
4
4
  def initialize(user)
5
5
  @user = user
6
6
  @token = ENV['SLACK_API_TOKEN'] || ""
7
- @image = ENV['SLACK_BOT_IMG'] || ""
7
+ @image = ENV['SLACK_BOT_IMG'] || "http://i.imgur.com/EEdDLWz.png"
8
8
  end
9
9
 
10
10
  def says(message)
@@ -12,7 +12,8 @@ module Say2Slack
12
12
  return [
13
13
  "#{endpoint}?token=#{@token}",
14
14
  "username=#{@user}",
15
- "text=#{message}"
15
+ "text=#{message}",
16
+ "icon_url=#{@image}",
16
17
  ].join("&")
17
18
  end
18
19
  end
@@ -1,3 +1,3 @@
1
1
  module Say2Slack
2
- VERSION = '0.0.3'
2
+ VERSION = '0.0.6'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: say2slack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Prokesch
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-06 00:00:00.000000000 Z
11
+ date: 2015-05-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client