From: Graham Knop Date: Fri, 1 Dec 2017 01:28:15 +0000 (+0100) Subject: fix tar type handling for uncompressed tar files X-Git-Tag: v0.003000~5 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=38513b0a4bcd3d64b0f8068dfbd01e65e26dccd7;p=p5sagit%2FDistar.git fix tar type handling for uncompressed tar files --- diff --git a/helpers/verify-tarball b/helpers/verify-tarball index 0da438b..eb62f8b 100755 --- a/helpers/verify-tarball +++ b/helpers/verify-tarball @@ -12,16 +12,16 @@ GetOptions( my ($tarball, $manifest) = @ARGV; my $type - = $tarball =~ /\.bz2$/ ? 'j' - : $tarball =~ /\.xz$/ ? 'J' - : $tarball =~ /\.t?gz$/ ? 'z' - : $tarball =~ /\.Z$/ ? 'Z' + = $tarball =~ /\.bz2$/ ? '-j' + : $tarball =~ /\.xz$/ ? '-J' + : $tarball =~ /\.t?gz$/ ? '-z' + : $tarball =~ /\.Z$/ ? '-Z' : ''; my @tarfiles; { my $null = File::Spec->devnull; - @tarfiles = `$tar -t -$type -f $tarball 2>$null`; + @tarfiles = `$tar -t $type -f "$tarball" 2>$null`; chomp @tarfiles; }