Skip to content

Commit

Permalink
Adds script which scrolls through all releases.
Browse files Browse the repository at this point in the history
  • Loading branch information
oalders committed Oct 16, 2014
1 parent 9eaac0a commit 5f9c7ec
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
27 changes: 27 additions & 0 deletions scripts/endpoints/release/7-all-releases.pl
@@ -0,0 +1,27 @@
#!/usr/bin/env perl

use strict;
use warnings;
use feature qw( say );

use Data::Printer;
use MetaCPAN::Util qw( es );

my $scroller = es()->scroll_helper(
search_type => 'scan',
scroll => '5m',
index => 'v0',
type => 'release',
size => 1000,
body => {
query => {
match_all => {}
},
fields => ['download_url'],
}
);

my @urls;
while ( my $result = $scroller->next ) {
push @urls, $result->{fields}->{download_url};
}
1 change: 0 additions & 1 deletion scripts/endpoints/release/all-releases-by-author.pl
Expand Up @@ -4,7 +4,6 @@
use warnings;
use feature qw( say );

use DateTime;
use MetaCPAN::Util qw( es );

my $uploads = es()->search(
Expand Down

0 comments on commit 5f9c7ec

Please sign in to comment.