Skip to content

Commit e965bc6

Browse files
committed
tidy
1 parent 2dcf324 commit e965bc6

16 files changed

+48
-38
lines changed

bin/author.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
use v5.36;
44

55
use Cpanel::JSON::XS qw< decode_json >;
6-
use DateTime ();
7-
use Email::Valid ();
8-
use Encode ();
6+
use DateTime ();
7+
use Email::Valid ();
8+
use Encode ();
99
use Getopt::Long;
1010
use MetaCPAN::Logger qw< :log :dlog >;
11-
use URI ();
11+
use URI ();
1212

1313
use MetaCPAN::ES;
1414
use MetaCPAN::Ingest qw<

bin/backpan.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ ()
5252
(
5353
$undo
5454
or exists $cpan_file_map->{$author}{$archive}
55-
)
55+
)
5656
? 'cpan'
5757
: 'backpan',
5858
$release->{_id}

bin/backup.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
use Getopt::Long;
77
use MetaCPAN::Logger qw< :log :dlog >;
88
use Cpanel::JSON::XS qw< decode_json encode_json >;
9-
use DateTime ();
10-
use IO::Zlib ();
11-
use Path::Tiny qw< path >;
12-
use Try::Tiny qw< catch try >;
9+
use DateTime ();
10+
use IO::Zlib ();
11+
use Path::Tiny qw< path >;
12+
use Try::Tiny qw< catch try >;
1313

1414
use MetaCPAN::ES;
1515
use MetaCPAN::Ingest qw< home >;

bin/checksum.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use v5.36;
44

55
use Getopt::Long;
6-
use Digest::file qw< digest_file_hex >;
6+
use Digest::file qw< digest_file_hex >;
77
use MetaCPAN::Logger qw< :log :dlog >;
88

99
use MetaCPAN::ES;

bin/cpan_testers.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
use warnings;
33
use v5.36;
44

5-
use DBI ();
5+
use DBI ();
66
use File::stat qw< stat >;
77
use Getopt::Long;
88
use IO::Uncompress::Bunzip2 qw< bunzip2 >;

bin/cve.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use Cpanel::JSON::XS qw< decode_json >;
66
use Getopt::Long;
77
use Path::Tiny qw< path >;
8-
use Ref::Util qw< is_arrayref >;
8+
use Ref::Util qw< is_arrayref >;
99

1010
use MetaCPAN::Logger qw< :log :dlog >;
1111

bin/first.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
$release
3939
? log_debug {
4040
"@{[ $release->name ]} by @{[ $release->author ]} was first"
41-
}
41+
}
4242
: log_warn {
4343
"no release found for distribution @{[$distribution->name]}"
4444
};

bin/latest.pl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77

88
use CPAN::DistnameInfo;
99
use Parse::CPAN::Packages::Fast;
10-
use Ref::Util qw< is_arrayref is_hashref >;
10+
use Ref::Util qw< is_arrayref is_hashref >;
1111
use Regexp::Common qw< time >;
12-
use Time::Local qw< timelocal >;
12+
use Time::Local qw< timelocal >;
1313

1414
use MetaCPAN::ES;
1515
use MetaCPAN::Ingest qw<
@@ -313,7 +313,7 @@ ( $bulk, $source, $status )
313313

314314
log_info {
315315
$status eq 'latest' ? 'Upgrading ' : 'Downgrading ',
316-
'release ', $release->{name}
316+
'release ', $release->{name}
317317
};
318318

319319
# Get all the files for the release.

bin/queue.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use v5.36;
44

55
use Getopt::Long;
6-
use Path::Tiny qw< path >;
6+
use Path::Tiny qw< path >;
77
use Path::Iterator::Rule ();
88

99
use MetaCPAN::Ingest qw< minion >;

bin/release.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
use Getopt::Long;
99
use List::Util qw< uniq >;
1010
use Path::Tiny qw< path >;
11-
use Try::Tiny qw< catch try >;
11+
use Try::Tiny qw< catch try >;
1212

1313
use MetaCPAN::Logger qw< :log :dlog >;
1414

@@ -121,7 +121,7 @@
121121
$find = $find->mtime( ">" . ( time - $age * 3600 ) )
122122
if $age;
123123
push( @files,
124-
map { $_->{file} }
124+
map { $_->{file} }
125125
sort { $a->{mtime} <=> $b->{mtime} }
126126
map { +{ file => $_, mtime => File::stat::stat($_)->mtime } }
127127
$find->in($_) );

bin/snapshot.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
use warnings;
33
use v5.36;
44

5-
use Cpanel::JSON::XS qw< decode_json encode_json >;
5+
use Cpanel::JSON::XS qw< decode_json encode_json >;
66
use DateTime ();
77
use DateTime::Format::ISO8601 ();
88
use HTTP::Tiny ();

bin/tickets.pl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44

55
use MetaCPAN::Logger qw< :log :dlog >;
66

7-
use Ref::Util qw< is_hashref is_ref >;
7+
use Ref::Util qw< is_hashref is_ref >;
88
use HTTP::Request::Common qw< GET >;
9-
use URI::Escape qw< uri_escape >;
10-
use Text::CSV_XS ();
11-
use Net::GitHub::V4 ();
9+
use URI::Escape qw< uri_escape >;
10+
use Text::CSV_XS ();
11+
use Net::GitHub::V4 ();
1212

1313
use MetaCPAN::ES;
1414
use MetaCPAN::Ingest qw<
@@ -101,7 +101,7 @@ ($tsv)
101101
source => _rt_dist_url( $row->{dist} ),
102102
active => $row->{active},
103103
closed => $row->{inactive},
104-
map { $_ => $row->{$_} + 0 }
104+
map { $_ => $row->{$_} + 0 }
105105
grep { not /^(dist|active|inactive)$/ }
106106
keys %$row,
107107
};

bin/watcher.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
use warnings;
33
use v5.36;
44

5-
use Cpanel::JSON::XS qw< decode_json >;
5+
use Cpanel::JSON::XS qw< decode_json >;
66
use DateTime ();
77
use CPAN::DistnameInfo ();
88
use FindBin ();

lib/MetaCPAN/ES.pm

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,9 @@ sub clear_type ($self) {
142142
$self->delete_ids(@$ids);
143143
}
144144

145-
sub await ( $self ) {
145+
sub await ($self) {
146146
my $timeout = 15;
147-
my $iready = 0;
147+
my $iready = 0;
148148
my $cluster_info;
149149
my $es = $self->{es};
150150

@@ -158,19 +158,29 @@ sub await ( $self ) {
158158
$iready = $es->ping;
159159

160160
if ($iready) {
161-
log_info { sprintf("Awaiting %d / %d : ready", $iseconds, $timeout) };
161+
log_info {
162+
sprintf( "Awaiting %d / %d : ready",
163+
$iseconds, $timeout )
164+
};
162165
$cluster_info = \%{ $es->info };
163166
}
164167
};
165168

166169
if ($@) {
167170
if ( $iseconds < $timeout ) {
168-
log_info { sprintf("Awaiting %d / %d : unavailable - sleeping ...", $iseconds, $timeout) };
171+
log_info {
172+
sprintf(
173+
"Awaiting %d / %d : unavailable - sleeping ...",
174+
$iseconds, $timeout )
175+
};
169176
sleep(1);
170177
$iseconds++;
171178
}
172179
else {
173-
log_info { sprintf("Awaiting %d / %d : unavailable - timeout!", $iseconds, $timeout) };
180+
log_info {
181+
sprintf( "Awaiting %d / %d : unavailable - timeout!",
182+
$iseconds, $timeout )
183+
};
174184

175185
#Set System Error: 112 - EHOSTDOWN - Host is down
176186
handle_error( 112, $@, 1 );

lib/MetaCPAN/File.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use warnings;
55
use v5.36;
66

77
use List::AllUtils qw< any >;
8-
use Path::Tiny qw< path >;
8+
use Path::Tiny qw< path >;
99

1010
use MetaCPAN::Logger qw< :log :dlog >;
1111

lib/MetaCPAN/Release.pm

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ use warnings;
55
use v5.36;
66

77
use CPAN::Meta;
8-
use DateTime ();
9-
use File::Spec ();
10-
use Module::Metadata 1.000012 (); # Improved package detection.
11-
use Path::Tiny qw< path >;
12-
use Plack::MIME ();
13-
use Try::Tiny qw< catch try >;
8+
use DateTime ();
9+
use File::Spec ();
10+
use Module::Metadata 1.000012 (); # Improved package detection.
11+
use Path::Tiny qw< path >;
12+
use Plack::MIME ();
13+
use Try::Tiny qw< catch try >;
1414

1515
use MetaCPAN::Logger qw< :log :dlog >;
1616

0 commit comments

Comments
 (0)