• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags

Frequently used words (click to add to your profile)

javaandroidc++linuxc#objective-ccocoa誰得qtrubypythonwindowsphpgamebathyscaphegui翻訳comegattwitterframeworkbtronvb.net計画中(planning stage)testdomarduinodirectxpreviewerゲームエンジン

Commit MetaInfo

Revisionde51d7c759e0c5625a2577a5518bde4a927191c8 (tree)
Zeit2009-03-27 00:09:45
Autorsoutaro <soutaro@f836...>
Commitersoutaro

Log Message

For release package: standard plugins locations should be updated for installation

git-svn-id: http://dev.ikejima.org/src/svn/pragger/trunk@398 f8368ae4-1e99-dc11-9799-0018f35ab5fa

Ändern Zusammenfassung

Diff

--- a/pragger.rb
+++ b/pragger.rb
@@ -12,7 +12,7 @@ class Plugin
1212 def initialize(file)
1313 instance_eval( @source = File.read(file).toutf8, file , 1)
1414 end
15- def self.load_plugins(folder = (Pathname.new(__FILE__).parent + "plugin"))
15+ def self.load_plugins(folder = (Pathname(__FILE__).parent + "plugin"))
1616 Pathname.glob(folder + "**/*.rb").sort.each do |file|
1717 begin
1818 $plugins[ file.relative_path_from(folder).to_s.gsub("/","::")[0..-4] ]= Plugin.new(file)
@@ -32,10 +32,10 @@ Plugin.load_plugins()
3232 configFile = "config.yaml"
3333 opt = OptionParser.new
3434 opt.on("-c", "--configfile CONFIGFILE") {|v| configFile = v }
35-opt.on("-p", "--plugindir PLUGINDIR") {|v| Plugin.load_plugins(Pathname.new(v)) }
35+opt.on("-p", "--plugindir PLUGINDIR") {|v| Plugin.load_plugins(Pathname(v)) }
3636 opt.on("-u", "--pluginusage PLUGINNAME") {|v| $plugins[v].source.gsub(/^## ?(.*)/){ puts $1 }; exit }
3737 opt.on("-l", "--listplugin") { $plugins.keys.sort.each{|k| puts k }; exit }
38-opt.on("-w", "--where") { puts(Pathname.new(__FILE__).parent + "plugin"); exit }
38+opt.on("-w", "--where") { puts(Pathname(__FILE__).parent + "plugin"); exit }
3939 opt.parse!
4040
4141 eval_pragger(YAML.load(File.read(configFile).toutf8.gsub(/base64::([\w+\/]+=*)/){ Base64.decode64($1) }),[])