Module: Del
- Defined in:
- lib/del.rb,
lib/del/user.rb,
lib/del/robot.rb,
lib/del/source.rb,
lib/del/message.rb,
lib/del/version.rb,
lib/del/connection.rb,
lib/del/repository.rb,
lib/del/configuration.rb,
lib/del/default_router.rb
Defined Under Namespace
Classes: Configuration, Connection, DefaultRouter, Message, Repository, Robot, Source, User
Constant Summary
collapse
- VERSION =
"0.1.5"
Class Method Summary
collapse
Class Method Details
.configuration ⇒ Object
37
38
39
|
# File 'lib/del.rb', line 37
def self.configuration
@configuration ||= Configuration.new
end
|
33
34
35
|
# File 'lib/del.rb', line 33
def self.configure
yield configuration
end
|
.logger ⇒ Object
41
42
43
|
# File 'lib/del.rb', line 41
def self.logger
@logger ||= configuration.logger
end
|
.start(dotenv_file:, startup_file:) ⇒ Object
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# File 'lib/del.rb', line 19
def self.start(dotenv_file:, startup_file:)
puts "Loading... #{dotenv_file}"
Dotenv.load(dotenv_file.to_s)
Del.configure do |config|
config.router.register(/.*/) do |message|
logger.debug(message.to_s)
end
end
load startup_file if startup_file && File.exist?(startup_file)
del = Robot.new(configuration: configuration)
del.get_funky!
end
|