Sha256: 5c9fd340f6bc2a02c263f78650f73a22172d76fdc86905bcc842038410733e5a
Contents?: true
Size: 848 Bytes
Versions: 2
Compression:
Stored size: 848 Bytes
Contents
#!/usr/bin/env ruby require "../lib/como" include Como Spec.command( "como_options", "Como Tester", "2013", [ [ :exclusive, "doc", nil, "Documentation for option\n\twith too much description\n\tfor one line." ], [ :single, "file", "-f", "File argument." ], [ :opt_comp, "attributes", "-a", "Attributes." ], [ :switch, "debug", nil, "Enable debugging." ], [ :opt_single, "mode", "-m", "Mode." ], [ :opt_multi, "params", nil, "Parameters." ], [ :opt_any, "types", "-t", "Types." ], [ :silent, "terminator", "-", "The terminator." ], [ :multi, "dir", "-d", "Directory argument(s)." ], [ :default, "Leftovers." ], ] ) Opt.each do |o| puts "Given \"#{o.name}\": #{o.given}" puts "Value \"#{o.name}\": #{o.value}" if o.given && o.value end if Opt.external puts "External: #{Opt.external}" end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
como-0.2.4 | test/como_options |
como-0.2.3 | test/como_options |