Version? Getopt::Long

M

Mark J Fenbers

I'm giving tech support to someone and suspect his version of
GetOpt::Long is older than mine. What simple test can be given on the
command-line to determine what version is being used on his computer?
Perhaps something like:

perl -MAppConfig -e' print_version()'

or something along those lines...

Mark
 
P

Paul Lalli

Mark J Fenbers said:
I'm giving tech support to someone and suspect his version of
GetOpt::Long is older than mine. What simple test can be given on the
command-line to determine what version is being used on his computer?
Perhaps something like:

perl -MAppConfig -e' print_version()'

or something along those lines...

The canonical way is:

perl -MGetopt::Long -e 'print $Getopt::Long::VERSION'

Of course, that would depend upon the author of this module following
the convention of creating a package variable $VERSION with the
appropriate information.

Paul Lalli
 
J

Johan Vromans

Paul Lalli said:
The canonical way is:

perl -MGetopt::Long -e 'print $Getopt::Long::VERSION'

Of course, that would depend upon the author of this module following
the convention of creating a package variable $VERSION with the
appropriate information.

.... which he does :).

This will also work:

% perl -MGetopt::Long=3.00
Getopt::Long version 3.00 required--this is only version 2.34 ...

-- Johan
Author and maintainer of the one and only Getopt::Long.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top