Module: Ircbot
- Extended by:
- Ircbot
- Included in:
- Ircbot
- Defined in:
- lib/ircbot/dm.rb,
lib/ircbot/plugin.rb,
lib/ircbot/plugins.rb,
lib/ircbot/version.rb,
lib/ircbot/framework.rb,
lib/ircbot/client/core.rb,
lib/ircbot/client/config.rb,
lib/ircbot/client/logger.rb,
lib/ircbot/utils/watcher.rb,
lib/ircbot/client/plugins.rb,
lib/ircbot/client/timeout.rb,
lib/ircbot/client/commands.rb,
lib/ircbot/client/encoding.rb,
lib/ircbot/client/eventable.rb,
lib/ircbot/client/standalone.rb,
lib/ircbot/utils/html_parser.rb,
lib/ircbot/client/config/plugins.rb,
lib/ircbot/client/config/channels.rb,
lib/ircbot/client/config/generator.rb
Defined Under Namespace
Modules: DM, Utils
Classes: Client, Plugin, PluginNotFound, Plugins
Constant Summary
collapse
- VERSION =
'0.2.2'
- HOMEPAGE =
"http://github.com/maiha/ircbot"
Instance Attribute Summary collapse
Instance Method Summary
collapse
Instance Attribute Details
#toplevel_binding ⇒ Object
Returns the value of attribute toplevel_binding.
29
30
31
|
# File 'lib/ircbot/framework.rb', line 29
def toplevel_binding
@toplevel_binding
end
|
Instance Method Details
#glob_for(type, name) ⇒ Object
23
24
25
26
27
|
# File 'lib/ircbot/framework.rb', line 23
def glob_for(type, name)
Array(paths[type]).reverse.select{|p| p.directory?}.map{|d|
Dir.glob(d + "**/#{name}.*")
}.flatten.compact.map{|i| Pathname(i)}
end
|
2
3
4
|
# File 'lib/ircbot/framework.rb', line 2
def paths
@paths ||= Mash.new
end
|
#push_path(type, path) ⇒ Object
18
19
20
21
|
# File 'lib/ircbot/framework.rb', line 18
def push_path(type, path)
paths[type] ||= []
paths[type] << Pathname(path)
end
|
6
7
8
|
# File 'lib/ircbot/framework.rb', line 6
def root
@root || Pathname(Dir.pwd).expand_path
end
|
#root=(value) ⇒ Object
14
15
16
|
# File 'lib/ircbot/framework.rb', line 14
def root=(value)
@root = Pathname(value)
end
|
#system_root ⇒ Object
10
11
12
|
# File 'lib/ircbot/framework.rb', line 10
def system_root
(Pathname(File.dirname(__FILE__)) + ".." + "..").expand_path
end
|