-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added new ant target to generate unique list of hostnames
- Loading branch information
Alex Stuart
authored and
Alex Stuart
committed
Jul 29, 2015
1 parent
45e9fe6
commit 83ae1b8
Showing
2 changed files
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| #!/usr/bin/perl -w | ||
|
|
||
| use Xalan; | ||
|
|
||
| open(XML, xalanCall . " -IN ../mdx/uk/collected.xml -XSL extract_locs.xsl|") || die "could not open input file"; | ||
| while (<XML>) { | ||
| chop; | ||
| if (/^https:\/\/([^\/:]+)(:\d+)?(\/|$)/) { | ||
| my $location = $1; | ||
| $locations{$location} = 1; | ||
| } | ||
| } | ||
| close XML; | ||
|
|
||
| foreach $loc (sort keys %locations) { | ||
| if ($loc =~ /([^:]+)/) { | ||
| print "$1\n"; | ||
| } | ||
| } |