slack-smart-bot 1.4.0 → 1.4.1
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 +4 -4
- data/lib/slack-smart-bot.rb +3 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d67db01b571c542e66d72812e3a928bc3077e3decf3cb517dfe0cc2648c3c6ad
|
4
|
+
data.tar.gz: 1002d186b7db6c1fadbc1ce016664584af53f95e508a932aea080b8ca5a681ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 226240c6a8cce706189f37cf2de8b8467369b3ed428b39a6144d655f90058c50b1f4bc2bd4b4b12e8333e753b7f7c60624ca999b9b0fda5ff13b49e965c07963
|
7
|
+
data.tar.gz: 716dda07932fe0636af2e29c5a55b36fd595103bf935596fde7a9985236362c7217f1e702f1128294df1a07fa7685dffeaaf8825cae0f720bbbab6a63b7175ee
|
data/lib/slack-smart-bot.rb
CHANGED
@@ -153,10 +153,12 @@ class SlackSmartBot
|
|
153
153
|
@bots_created.each { |key, value|
|
154
154
|
if !value.key?(:cloud) or (value.key?(:cloud) and value[:cloud] == false)
|
155
155
|
@logger.info "ruby #{config.file_path} \"#{value[:channel_name]}\" \"#{value[:admins]}\" \"#{value[:rules_file]}\" #{value[:status].to_sym}"
|
156
|
+
puts "Starting #{value[:channel_name]} Smart Bot"
|
156
157
|
t = Thread.new do
|
157
158
|
`ruby #{config.file_path} \"#{value[:channel_name]}\" \"#{value[:admins]}\" \"#{value[:rules_file]}\" #{value[:status].to_sym}`
|
158
159
|
end
|
159
160
|
value[:thread] = t
|
161
|
+
sleep value[:admins].size
|
160
162
|
end
|
161
163
|
}
|
162
164
|
end
|
@@ -169,6 +171,7 @@ class SlackSmartBot
|
|
169
171
|
config.admins.each do |au|
|
170
172
|
user_info = client.web_client.users_info(user: "@#{au}")
|
171
173
|
@admin_users_id << user_info.user.id
|
174
|
+
sleep 1
|
172
175
|
end
|
173
176
|
rescue Slack::Web::Api::Errors::TooManyRequestsError
|
174
177
|
@logger.fatal "TooManyRequestsError"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: slack-smart-bot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mario Ruiz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-12-
|
11
|
+
date: 2019-12-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: slack-ruby-client
|