slack-smart-bot 1.12.2 → 1.12.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/slack/smart-bot/commands/on_bot/general/bot_stats.rb +19 -7
- data/whats_new.txt +1 -1
- metadata +19 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 27a01c9632e3e892e2c21142658a3c77e8a11ab0d6a025abc6b9ccaf189b9af5
|
4
|
+
data.tar.gz: 916f5a09a3e121f768ca5a07e4721c5b33ee9c475a6697047ab83c9026e9b27d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 002ecefc0542c4240f011930fd92d6330ff6d67bab530f7988b453696ff9936767ca88fc9d15e101d906744a27fc6921546e35f2a0e9e5856bed62848c827166
|
7
|
+
data.tar.gz: dbabcdb3e6f40da61085cad5ebbbe24a260c9f9a952dc7782f380ed58133fab811985546051636c69788c407d6c39664d419e1ea610a9b7d9019bf81bb619481
|
@@ -375,19 +375,31 @@ class SlackSmartBot
|
|
375
375
|
message << "*Time Zones*"
|
376
376
|
total_known = 0
|
377
377
|
tzone_users.each do |tzone, num|
|
378
|
-
|
379
|
-
|
378
|
+
unless tzone.to_s == ''
|
379
|
+
message << "\t#{tzone}: #{num} (#{(num.to_f*100/total_without_routines).round(2)}%)"
|
380
|
+
total_known+=num
|
381
|
+
end
|
380
382
|
end
|
381
383
|
total_unknown = total_without_routines - total_known
|
382
384
|
message << "\tUnknown: #{total_unknown} (#{(total_unknown.to_f*100/total_without_routines).round(2)}%)" if total_unknown > 0
|
383
385
|
end
|
384
|
-
|
386
|
+
|
385
387
|
if job_title_users.size > 0
|
386
|
-
|
388
|
+
if job_title_users.size > 10
|
389
|
+
message << "*Job Titles* - #{job_title_users.size} (Top 10)"
|
390
|
+
else
|
391
|
+
message << "*Job Titles* - #{job_title_users.size}"
|
392
|
+
end
|
387
393
|
total_known = 0
|
388
|
-
|
389
|
-
|
390
|
-
|
394
|
+
i = 0
|
395
|
+
job_title_users.sort_by {|k,v| -v}.each do |jtitle, num|
|
396
|
+
unless jtitle.to_s == ''
|
397
|
+
i += 1
|
398
|
+
if i <= 10
|
399
|
+
message << "\t#{jtitle}: #{num} (#{(num.to_f*100/total_without_routines).round(2)}%)"
|
400
|
+
end
|
401
|
+
total_known+=num
|
402
|
+
end
|
391
403
|
end
|
392
404
|
total_unknown = total_without_routines - total_known
|
393
405
|
message << "\tUnknown: #{total_unknown} (#{(total_unknown.to_f*100/total_without_routines).round(2)}%)" if total_unknown > 0
|
data/whats_new.txt
CHANGED
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.12.
|
4
|
+
version: 1.12.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mario Ruiz
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-11-
|
11
|
+
date: 2022-11-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: slack-ruby-client
|
@@ -126,6 +126,20 @@ dependencies:
|
|
126
126
|
- - "~>"
|
127
127
|
- !ruby/object:Gem::Version
|
128
128
|
version: '3.9'
|
129
|
+
- !ruby/object:Gem::Dependency
|
130
|
+
name: console
|
131
|
+
requirement: !ruby/object:Gem::Requirement
|
132
|
+
requirements:
|
133
|
+
- - "~>"
|
134
|
+
- !ruby/object:Gem::Version
|
135
|
+
version: 1.15.0
|
136
|
+
type: :runtime
|
137
|
+
prerelease: false
|
138
|
+
version_requirements: !ruby/object:Gem::Requirement
|
139
|
+
requirements:
|
140
|
+
- - "~>"
|
141
|
+
- !ruby/object:Gem::Version
|
142
|
+
version: 1.15.0
|
129
143
|
description: "Create a Slack bot that is smart and so easy to expand, create new bots
|
130
144
|
on demand, run ruby code on chat, create shortcuts... \n The main scope of this
|
131
145
|
gem is to be used internally in the company so teams can create team channels with
|
@@ -297,8 +311,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
297
311
|
- !ruby/object:Gem::Version
|
298
312
|
version: '0'
|
299
313
|
requirements: []
|
300
|
-
rubygems_version: 3.2
|
301
|
-
signing_key:
|
314
|
+
rubygems_version: 3.1.2
|
315
|
+
signing_key:
|
302
316
|
specification_version: 4
|
303
317
|
summary: Create a Slack bot that is smart and so easy to expand, create new bots on
|
304
318
|
demand, run ruby code on chat, create shortcuts...
|