Getopt::Long::CGI - Perl extension for command-line and CGI argument parsing.
use Getopt::Long::CGI; my $data = "file.dat"; my $length = 24; my $verbose; GetOptions ("length=i" => \$length, # numeric "file=s" => \$data, # string "verbose" => \$verbose) # flag or die("Error in command line arguments\n");
Using the same syntax as Getopt::Long, scripts work on the command-line in the same way. If the same script is called in a CGI-like environment it'll change mode and display an HTML form of the options accepted on the command-line - from which you can run the script and see the output.
Luke Ross, <firstname.lastname@example.org>
Copyright (C) 2014-2018 by Luke Ross
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.6.0 or, at your option, any later version of Perl 5 you may have available.