botwayrb 0.1.0 → 0.2.0
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/botwayrb/version.rb +1 -1
- data/lib/botwayrb.rb +9 -1
- 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: 6d97c4e55be1c3bc9867316c88d2a3ef351e0955ddf718a9b4ff440a076cb547
|
|
4
|
+
data.tar.gz: 0b81393d2e7bc1c0272d0dc307c8623a218fb09e25632cd9b2b3b732be00b750
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2502e3a0d6a605becc0bb6375059b423079a42979d08c21763212302d4ae78dd478f2dd2c80a35708f3945a9140703954119558534440e6b902732e53c3dbd57
|
|
7
|
+
data.tar.gz: bedadca5c2ee191592fb57561728445a3e702c5e456d0ac0013b010b490ba0e05fc5d259dba0e2d0de2f650428ba9c4d792efb78ec7ca186692cd71e5e190f24
|
data/lib/botwayrb/version.rb
CHANGED
data/lib/botwayrb.rb
CHANGED
|
@@ -4,7 +4,6 @@ require_relative "botwayrb/version"
|
|
|
4
4
|
require "yaml"
|
|
5
5
|
require "json"
|
|
6
6
|
|
|
7
|
-
|
|
8
7
|
module Botwayrb
|
|
9
8
|
BotwatConfig = JSON.parse(File.read(File.join(File.expand_path("~"), ".botway", "botway.json")))
|
|
10
9
|
|
|
@@ -46,5 +45,14 @@ module Botwayrb
|
|
|
46
45
|
BotwatConfig["botway"]["bots"][get_bot_info("name")]["guilds"][serverName]["server_id"]
|
|
47
46
|
end
|
|
48
47
|
end
|
|
48
|
+
|
|
49
|
+
def get_signing_secret()
|
|
50
|
+
if get_bot_info("lang") != "ruby"
|
|
51
|
+
raise Error, "ERROR: Botway is not running in Ruby"
|
|
52
|
+
elsif get_bot_info("type") != "slack"
|
|
53
|
+
raise Error, "ERROR: This function/feature is only working with slack bots."
|
|
54
|
+
else
|
|
55
|
+
BotwatConfig["botway"]["bots"][get_bot_info("name")]["signing_secret"]
|
|
56
|
+
end
|
|
49
57
|
end
|
|
50
58
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: botwayrb
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- abdfnx
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2022-05-
|
|
11
|
+
date: 2022-05-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: yaml
|