Testing
This commit is contained in:
@@ -13,7 +13,7 @@ module CliGen::Parser
|
||||
parser.banner = {{@type.name}}::HEADER
|
||||
{% subcommands = @type.class.methods.select(&.annotation(::CliGen::SubCommand)) %}
|
||||
{% if subcommands.size > 0 %}
|
||||
define_section("Subcommands", parser)
|
||||
CliGen::define_section("Subcommands", parser)
|
||||
{% for subcommand in subcommands %}
|
||||
{% subcommand_anno = subcommand.annotation(::CliGen::SubCommand) %}
|
||||
parser.on({{subcommand.name.stringify}}, {{subcommand_anno[:description]}}){
|
||||
@@ -24,7 +24,7 @@ module CliGen::Parser
|
||||
|
||||
{% arguments = @type.class.methods.select(&.annotation(::CliGen::CommandArgument)) %}
|
||||
{% if arguments.size > 0 %}
|
||||
define_section("Provide Arguments", parser)
|
||||
CliGen::define_section("Provide Arguments", parser)
|
||||
{% for argument in arguments %}
|
||||
{% argument_anno = argument.annotation(::CliGen::CommandArgument) %}
|
||||
{% if argument_anno[:short] == "" && argument_anno[:long] != "" %}
|
||||
|
||||
Reference in New Issue
Block a user