First draft of a tool to extract URLs from a text file
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use Regexp::Common 'URI';
|
||||
use IO::All;
|
||||
|
||||
foreach my $filename (@ARGV) {
|
||||
my $content = io->file($filename)->slurp;
|
||||
while ( $content =~ m/($RE{URI}{HTTP})/g ) {
|
||||
print $1, $/;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user