1
0
mirror of https://github.com/moparisthebest/gpgit synced 2024-08-13 15:53:50 -04:00

Exit with an error status code if the arguments are invalid

This commit is contained in:
Mike Cardwell 2011-02-24 10:50:19 +00:00
parent b3d4732b28
commit d16b607d70

1
gpgit.pl Normal file → Executable file
View File

@ -27,6 +27,7 @@ use MIME::Parser;
## Parse args
my $recipient_email = $ARGV[0]||'';
die "Bad arguments. Must supply a valid email address" unless $recipient_email =~ /^.+\@.+$/;
## Object for GPG encryption
my $gpg = new Mail::GnuPG();