Class: IrcMachine::Plugin::Reloader
- Inherits:
-
Base
- Object
- Base
- IrcMachine::Plugin::Reloader
show all
- Defined in:
- lib/irc_machine/plugin/reloader.rb
Instance Attribute Summary
Attributes inherited from Base
#session
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Class Method Details
.load_all ⇒ Object
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# File 'lib/irc_machine/plugin/reloader.rb', line 9
def self.load_all
files = %w{
core
core_routes
udp_server
http_controller
http_router
http_server
controller/channels_controller
controller/github_notifications_controller
plugin/github_notifier
plugin/base
plugin/hello
plugin/reloader
}.each do |name|
puts "loading: #{name}"
load "irc_machine/#{name}.rb"
end
end
|
Instance Method Details
#receive_line(line) ⇒ Object
3
4
5
6
7
|
# File 'lib/irc_machine/plugin/reloader.rb', line 3
def receive_line(line)
if line =~ /^:\S+ PRIVMSG #{session.state.nick} :reload$/
self.class.load_all
end
end
|