diff --git a/src/cligen/command/.argument.cr.swp b/src/cligen/command/.argument.cr.swp deleted file mode 100644 index a1f9328..0000000 Binary files a/src/cligen/command/.argument.cr.swp and /dev/null differ diff --git a/src/cligen/command/argument.cr b/src/cligen/command/argument.cr index 2b00492..8203c92 100644 --- a/src/cligen/command/argument.cr +++ b/src/cligen/command/argument.cr @@ -35,7 +35,11 @@ module CliGen {% end %} {% if options %} {% options = options.resolve if options.is_a? Path %} - {% raise "ERROR : CliGen::Command.argument(#{name}) : Provided options must be an ArrayLiteral" unless options.is_a? ArrayLiteral %} + {% if options.is_a? Call %} + {% elsif options.is_a? ArrayLiteral %} + {% else %} + {% raise "ERROR : CliGen::Command.argument(#{name}) : Provided options must be an ArrayLiteral or a runtime method call to retrieve data" %} + {% end %} {% end %} {% if format %} {% format = format.resolve if format.is_a? Path %}