Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/perl
- use warnings;
- use strict;
- my ($one, $two, %data) = ("", "", );
- my @list = qx/find .. -iname '*.7z' -exec 7z l -slt {} \\;/;
- foreach (@list) {
- $one = $1 if (/Path = (.*\.7z)/);
- $two = $1 if (/Path = (.+\.[^(7z\n)]+)/);
- if (/7-Zip/) {
- if (exists $data{$two}) {
- printf("DUP: %s\n%s\n", $data{$two}, $one);
- } else {
- $two =~ s#^\./##;
- $data{$two} = $one;
- }
- }
- }
- foreach my $key (sort keys %data) { printf("%s\n", $key) }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement