socrates 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/socrates/bots/cli_bot.rb +1 -2
- data/lib/socrates/bots/slack_bot.rb +2 -3
- data/lib/socrates/config.rb +1 -0
- data/lib/socrates/core/dispatcher.rb +1 -1
- data/lib/socrates/version.rb +1 -1
- data/socrates.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7aa5675086ee96c3c8a47ae71f43f3eeb834432c
|
4
|
+
data.tar.gz: 4ac0a6948f1b1c46a0adbba2fe82525016e452b2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ef7c44bf3192f787974b132c2b6291c82bc8c864a219727d6bb5e54c89393946379dd6b0dd8b674608d90e35a8b61541afc75a5d8b026708c16427d53d2e0995
|
7
|
+
data.tar.gz: fd2a4d81d1ffeb91abf02f0dd48d72a619da2b2cdf64d8c932bb1ff315897039509abc1c858c8407f607215c0439155e1a28f760f4136146366ee4a392d36b78
|
@@ -3,8 +3,7 @@ module Socrates
|
|
3
3
|
class CLIBot
|
4
4
|
def initialize(state_factory:)
|
5
5
|
@adapter = ConsoleAdapter.new
|
6
|
-
@
|
7
|
-
@dispatcher = Core::Dispatcher.new(storage: @storage, adapter: @adapter, state_factory: state_factory)
|
6
|
+
@dispatcher = Core::Dispatcher.new(adapter: @adapter, state_factory: state_factory)
|
8
7
|
end
|
9
8
|
|
10
9
|
def start
|
@@ -9,13 +9,12 @@ module Socrates
|
|
9
9
|
config.logger = Logger.new(STDOUT)
|
10
10
|
config.logger.level = Logger::INFO
|
11
11
|
|
12
|
-
raise "Missing ENV[SLACK_API_TOKEN]!" unless config.token
|
12
|
+
raise "Missing ENV['SLACK_API_TOKEN']!" unless config.token
|
13
13
|
end
|
14
14
|
|
15
15
|
@slack_client = Slack::RealTime::Client.new
|
16
16
|
@adapter = SlackAdapter.new(@slack_client)
|
17
|
-
@
|
18
|
-
@dispatcher = Core::Dispatcher.new(storage: @storage, adapter: @adapter, state_factory: state_factory)
|
17
|
+
@dispatcher = Core::Dispatcher.new(adapter: @adapter, state_factory: state_factory)
|
19
18
|
end
|
20
19
|
|
21
20
|
def start
|
data/lib/socrates/config.rb
CHANGED
@@ -11,7 +11,7 @@ module Socrates
|
|
11
11
|
def initialize(adapter:, state_factory:, storage: nil)
|
12
12
|
@adapter = adapter
|
13
13
|
@state_factory = state_factory
|
14
|
-
@storage = storage || Storage::MemoryStorage.new
|
14
|
+
@storage = storage || Socrates::Config.storage || Storage::MemoryStorage.new
|
15
15
|
|
16
16
|
@logger = Socrates::Config.logger || Socrates::Logger.default
|
17
17
|
@error_message = Socrates::Config.error_message || DEFAULT_ERROR_MESSAGE
|
data/lib/socrates/version.rb
CHANGED
data/socrates.gemspec
CHANGED
@@ -12,7 +12,7 @@ Gem::Specification.new do |spec|
|
|
12
12
|
spec.authors = ["Christian Nelson"]
|
13
13
|
spec.email = ["christian@carbonfive.com"]
|
14
14
|
|
15
|
-
spec.summary = "A
|
15
|
+
spec.summary = "A micro-framework for building stateful conversational bots."
|
16
16
|
spec.homepage = "https://github.com/carbonfive/socrates"
|
17
17
|
|
18
18
|
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: socrates
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christian Nelson
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -195,5 +195,5 @@ rubyforge_project:
|
|
195
195
|
rubygems_version: 2.6.11
|
196
196
|
signing_key:
|
197
197
|
specification_version: 4
|
198
|
-
summary: A
|
198
|
+
summary: A micro-framework for building stateful conversational bots.
|
199
199
|
test_files: []
|