Skip to content
Snippets Groups Projects
Commit e64552a3 authored by Guillaume ROUSSE's avatar Guillaume ROUSSE
Browse files

use Pod::Usage to display usage errors

parent e1d29f60
No related branches found
No related tags found
No related merge requests found
......@@ -14,6 +14,7 @@ use lib "/opt/testidp/IdPAccountManager/conf";
use Getopt::Long qw(:config auto_help);
use POSIX;
use Pod::Usage;
use IdPAccountManager::TestAccount;
use IdPAccountManager::SAMLMetadata;
......@@ -35,7 +36,10 @@ unless (
)
)
{
die "Unknown options.";
pod2usage(
-message => "unknown option, aborting\n",
-verbose => 0
);
}
if ($options{'add_test_account'}) {
......@@ -308,7 +312,10 @@ if ($options{'add_test_account'}) {
printf "Mail notice sent to $options{'email_address'}\n";
} else {
die "Missing arguments";
pod2usage(
-message => "missing argument, aborting\n",
-verbose => 0
);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment