Module: EacRubyUtils::Console::DocoptRunner::SubcommandsSupport::SubcommandArgAsArg

Defined in:
lib/eac_ruby_utils/console/docopt_runner/_subcommands.rb

Instance Method Summary collapse

Instance Method Details

#subcommand_nameObject


115
116
117
# File 'lib/eac_ruby_utils/console/docopt_runner/_subcommands.rb', line 115

def subcommand_name
  options.fetch(SUBCOMMAND_ARG)
end

#subcommands_target_docObject


119
120
121
122
123
# File 'lib/eac_ruby_utils/console/docopt_runner/_subcommands.rb', line 119

def subcommands_target_doc
  available_subcommands.inject("Subcommands:\n") do |a, e|
    a + "  #{e}\n"
  end
end

#target_doc_subcommand_argObject


111
112
113
# File 'lib/eac_ruby_utils/console/docopt_runner/_subcommands.rb', line 111

def target_doc_subcommand_arg
  SUBCOMMAND_ARG
end