Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
#!/usr/bin/env perl
use strict;
use warnings;
use Getopt::Long;
my @c = ();
my @m = ();
GetOptions('c=s' => \@c, 'm=s' => \@m);
my $argument = shift @ARGV;
die "a mandatory parameter `argument'" unless $argument;
use Data::Dumper; print Dumper {'c' => \@c, 'm' => \@m, 'argument' => $argument};
@kyanny
Owner
$ perl opt.pl -c name1 -c name2 -m name3 argument
$VAR1 = {
          'argument' => 'argument',
          'c' => [
                   'name1',
                   'name2'
                 ],
          'm' => [
                   'name3'
                 ]
        };
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.