slacky 0.2 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- slacky (0.2)
4
+ slacky (0.2.1)
5
5
  dotenv
6
6
  em-cron
7
7
  eventmachine
@@ -89,7 +89,6 @@ module Slacky
89
89
  @command_handlers.each do |h|
90
90
  command, handler = h.values_at :command, :handler
91
91
  next unless command == message.command
92
- @client.typing channel: message.channel.slack_id
93
92
  handler.call message
94
93
  handled = true
95
94
  end
@@ -100,9 +99,8 @@ module Slacky
100
99
  @channel_handlers.each do |h|
101
100
  match, channels, handler = h.values_at :match, :channels, :handler
102
101
  accept = Channel.find channels
103
- next if accept && accept.include?(message.channel)
102
+ next if accept && ! accept.include?(message.channel)
104
103
  next if match && ! match === message
105
- @client.typing channel: message.channel.slack_id
106
104
  handler.call message
107
105
  end
108
106
  end
@@ -118,7 +116,6 @@ module Slacky
118
116
  @command_handlers.each do |h|
119
117
  command, handler = h.values_at :command, :handler
120
118
  next unless command == message.command
121
- @client.typing channel: message.channel.slack_id
122
119
  handler.call message
123
120
  handled = true
124
121
  end
@@ -128,7 +125,6 @@ module Slacky
128
125
  @im_handlers.each do |h|
129
126
  match, handler = h.values_at :match, :handler
130
127
  next if match && ! match === message
131
- @client.typing channel: message.channel.slack_id
132
128
  handler.call message
133
129
  end
134
130
  end
@@ -25,6 +25,10 @@ module Slacky
25
25
  @@bot.client.message channel: @channel.slack_id, reply_to: @raw.id, text: msg
26
26
  end
27
27
 
28
+ def typing
29
+ @@bot.client.typing channel: @channel.slack_id
30
+ end
31
+
28
32
  def command?
29
33
  first = word 0
30
34
  return false unless first
@@ -1,3 +1,3 @@
1
1
  module Slacky
2
- VERSION = "0.2"
2
+ VERSION = "0.2.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slacky
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.2'
4
+ version: 0.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-05-26 00:00:00.000000000 Z
12
+ date: 2016-05-31 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: slack-ruby-client
@@ -226,7 +226,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
226
226
  version: '0'
227
227
  segments:
228
228
  - 0
229
- hash: 2539155529530202042
229
+ hash: -2329901822562595396
230
230
  required_rubygems_version: !ruby/object:Gem::Requirement
231
231
  none: false
232
232
  requirements:
@@ -235,7 +235,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
235
235
  version: '0'
236
236
  segments:
237
237
  - 0
238
- hash: 2539155529530202042
238
+ hash: -2329901822562595396
239
239
  requirements: []
240
240
  rubyforge_project:
241
241
  rubygems_version: 1.8.23