OSDN Git Service

Fix command class loader to support ruby1.9.x. v0.1.8
authorTatsuki Sugiura <sugi@nemui.org>
Wed, 15 Feb 2017 05:49:38 +0000 (14:49 +0900)
committerTatsuki Sugiura <sugi@nemui.org>
Wed, 15 Feb 2017 05:49:38 +0000 (14:49 +0900)
ChangeLog
lib/osdn/cli/runner.rb
lib/osdn/cli/version.rb

index 641f103..c47df02 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2017-02-15  Tatsuki Sugiura  <sugi@nemui.org>
+
+       * Fix command class loader to support ruby 1.9.x.
+       * Version 0.1.8
+
 2016-10-04  Tatsuki Sugiura  <sugi@nemui.org>
 
        * Version 0.1.7
index d9eeb4f..752b1d5 100644 (file)
@@ -55,7 +55,7 @@ module OSDN
       def get_command_class(command_name)
         class_name = command_name.to_s.split('_').map(&:capitalize).join
         begin
-          return self.class.const_get("OSDN::CLI::Command::#{class_name}")
+          return OSDN::CLI::Command.const_get(class_name)
         rescue NameError => e
           logger.fatal "Invalid command name '#{command_name}'. Use 'help' to list commands."
           exit
index 22045d1..3dffa84 100644 (file)
@@ -1,5 +1,5 @@
 module OSDN
   module CLI
-    VERSION = "0.1.7"
+    VERSION = "0.1.8"
   end
 end