Skip to content

Commit 9a0c4f4

Browse files
committed
Fixes Issue #44 - cpansign script not installed with version 0.92
1 parent 85017a2 commit 9a0c4f4

File tree

3 files changed

+32
-27
lines changed

3 files changed

+32
-27
lines changed

Makefile.PL

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,12 +234,15 @@ my %WriteMakefileArgs = (
234234
"ExtUtils::MakeMaker" => "6.36"
235235
},
236236
"DISTNAME" => "Module-Signature",
237+
"EXE_FILES" => [
238+
"script/cpansign"
239+
],
237240
"LICENSE" => "perl",
238241
"NAME" => "Module::Signature",
239242
"PREREQ_PM" => {
240243
"File::Temp" => 0
241244
},
242-
"VERSION" => "0.91",
245+
"VERSION" => "0.93",
243246
"test" => {
244247
"TESTS" => "t/*.t"
245248
}

dist.ini

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ ExtUtils::MakeMaker = 6.36
3636
[ReadmeFromPod]
3737
[ExtraTests]
3838
[ExecDir]
39+
dir = script
40+
3941
[ShareDir]
4042
[TestRelease]
4143
[ConfirmRelease]

script/cpansign

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
#!/usr/bin/perl
2+
use strict;
3+
use Module::Signature;
24

3-
$VERSION = '0.06';
5+
# PODNAME: cpansign
6+
my $VERSION = '0.07';
47

58
=encoding utf8
69
@@ -10,30 +13,27 @@ cpansign - CPAN signature management utility
1013
1114
=head1 SYNOPSIS
1215
13-
% cpansign # verify an existing SIGNATURE, or
14-
# make a new one if none exists
16+
% cpansign # verify an existing SIGNATURE, or
17+
# make a new one if none exists
1518
16-
% cpansign file.par # verify or sign a PAR file
19+
% cpansign file.par # verify or sign a PAR file
1720
18-
% cpansign sign # make signature; overwrites existing one
19-
% cpansign -s # same thing
21+
% cpansign sign # make signature; overwrites existing one
22+
% cpansign -s # same thing
2023
21-
% cpansign verify # verify a signature
22-
% cpansign -v # same thing
24+
% cpansign verify # verify a signature
25+
% cpansign -v # same thing
2326
% cpansign -v --skip # ignore files in MANIFEST.SKIP
2427
25-
% cpansign help # display this documentation
26-
% cpansign -h # same thing
28+
% cpansign help # display this documentation
29+
% cpansign -h # same thing
2730
2831
=head1 DESCRIPTION
2932
30-
This utility lets you create and verify SIGNATURE files.
33+
This utility lets you create and verify SIGNATURE files.
3134
3235
=cut
3336

34-
use strict;
35-
use Module::Signature;
36-
3737
$Module::Signature::Verbose = 1;
3838

3939
my %cmd = (
@@ -52,27 +52,27 @@ if (!$op or $op eq 'skip' or -e $op) {
5252
my $cmd = $cmd{substr($op, 0, 1)};
5353
(system("perldoc $0"), exit) if $cmd eq 'help';
5454
my @args;
55-
push @args, (overwrite => '1') if $cmd eq 'sign';
56-
push @args, (skip => '1') if grep /^-?-?skip/, @ARGV;
55+
push @args, (overwrite => '1') if $cmd eq 'sign';
56+
push @args, (skip => '1') if grep /^-?-?skip/, @ARGV;
5757

5858
if (my $sub = Module::Signature->can($cmd)) {
5959
if (@ARGV and -e $ARGV[-1]) {
60-
require PAR::Dist;
61-
PAR::Dist::_verify_or_sign(
62-
dist => $ARGV[-1],
63-
$dwim ? () : (action => $cmd, @args)
64-
);
60+
require PAR::Dist;
61+
PAR::Dist::_verify_or_sign(
62+
dist => $ARGV[-1],
63+
$dwim ? () : (action => $cmd, @args)
64+
);
6565
}
6666
else {
67-
#if ($cmd eq 'sign') {
68-
# exit unless Module::Signature::verify();
69-
#}
70-
exit($sub->(@args));
67+
#if ($cmd eq 'sign') {
68+
# exit unless Module::Signature::verify();
69+
#}
70+
exit($sub->(@args));
7171
}
7272
}
7373
else {
7474
die "Unknown command: '$op'.\n".
75-
"Available actions: " . (join(', ', sort values %cmd)) . ".\n";
75+
"Available actions: " . (join(', ', sort values %cmd)) . ".\n";
7676
}
7777

7878
exit;

0 commit comments

Comments
 (0)