summaryrefslogtreecommitdiff
path: root/lib/coderay/helpers
diff options
context:
space:
mode:
authormurphy <murphy@rubychan.de>2008-01-07 14:42:47 +0000
committermurphy <murphy@rubychan.de>2008-01-07 14:42:47 +0000
commite127b7d57b06554e708752bbbc2a85e833633c26 (patch)
treeccd44c344594ccacdcd95a1e1dfc35488cb2c58d /lib/coderay/helpers
parentbbbbc70a0b2efcd03bbcaf4e08ac139e7969e608 (diff)
downloadcoderay-e127b7d57b06554e708752bbbc2a85e833633c26.tar.gz
Lib:
- Encoder: removed a warning - Encoders::HTML: don't shadow outer variable - Plugin: move require_plugin into class namespace - Ruby Scanner: - "alias" keyword recognition - better regexp/division distinction - recognize ~, !, !=, and !~ as method names (partly Ruby 1.9 only) - reordered states for speed Tests: - updated coderay-suite to use gem instead of require_gem - general improvements (more colors!, new parameter: new, new syntax lang.test for only and new) - fixed ruby suite - adjusted a lot of Ruby tests (alias uses methods now) - new tests: ruby/operators, ruby/regexp Samples: - fixed/updated ('bout time) Rake tasks: - updated to use new rubygems API
Diffstat (limited to 'lib/coderay/helpers')
-rw-r--r--lib/coderay/helpers/plugin.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/coderay/helpers/plugin.rb b/lib/coderay/helpers/plugin.rb
index e6017d5..e1a945f 100644
--- a/lib/coderay/helpers/plugin.rb
+++ b/lib/coderay/helpers/plugin.rb
@@ -22,7 +22,7 @@ module CodeRay
#
# Generators[:fancy] #-> FancyGenerator
# # or
-# require_plugin 'Generators/fancy'
+# CodeRay.require_plugin 'Generators/fancy'
module PluginHost
# Raised if Encoders::[] fails because:
@@ -318,7 +318,7 @@ end
# CodeRay.require_plugin '<Host ID>/<Plugin ID>'
#
# Returns the loaded plugin.
-def require_plugin path
+def self.require_plugin path
host_id, plugin_id = path.split '/', 2
host = PluginHost.host_by_id(host_id)
raise PluginHost::HostNotFound,