lib/cloudstack-cli/base.rb in cloudstack-cli-1.2.4 vs lib/cloudstack-cli/base.rb in cloudstack-cli-1.2.5

- old
+ new

@@ -1,6 +1,7 @@ require "thor" +require "cloudstack-cli/thor_patch" require "yaml" require "open-uri" module CloudstackCli class Base < Thor @@ -32,9 +33,19 @@ # exit with return code 1 in case of a error def self.exit_on_failure? true end + + # fix for subcommand help issues + # see https://github.com/erikhuda/thor/issues/261 + # def self.banner(command, namespace = nil, subcommand = false) + # "#{basename} #{subcommand_prefix} #{command.usage}" + # end + # + # def self.subcommand_prefix + # self.name.gsub(%r{.*::}, '').gsub(%r{^[A-Z]}) { |match| match[0].downcase }.gsub(%r{[A-Z]}) { |match| "-#{match[0].downcase}" } + # end no_commands do def client @config ||= load_configuration @client ||= CloudstackClient::Client.new(