Changeset 2082
- Timestamp:
- 2001-02-28T15:59:12+13:00 (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/perllib/plugins/ZIPPlug.pm
r1812 r2082 30 30 # gzip (.gz, .z, .tgz, .taz) 31 31 # bzip (.bz) 32 # bzip2 (.bz2) 32 33 # zip (.zip .jar) 33 34 # tar (.tar) … … 38 39 # gunzip (for gzip) 39 40 # bunzip (for bzip) 41 # bunzip2 40 42 # unzip (for zip) 41 43 # tar (for tar) … … 82 84 return undef if ($ENV{'GSDLOS'} =~ /^windows$/i); 83 85 84 if ($file =~ /\.(gz|tgz|z|taz|bz| zip|jar|tar)$/i) {86 if ($file =~ /\.(gz|tgz|z|taz|bz|bz2|zip|jar|tar)$/i) { 85 87 86 88 my $filename = &util::filename_cat ($base_dir, $file); … … 103 105 if ($file =~ /\.bz$/i) { 104 106 $self->bunzip ($file_only); 107 } elsif ($file =~ /\.bz2$/i) { 108 $self->bunzip2 ($file_only); 105 109 } elsif ($file =~ /\.(zip|jar)$/i) { 106 110 $self->unzip ($file_only); … … 126 130 my ($file) = @_; 127 131 if (system ("bunzip $file")!=0) 132 { 133 &util::rm ($file); 134 } 135 } 136 137 sub bunzip2 { 138 my $self = shift (@_); 139 my ($file) = @_; 140 if (system ("bunzip2 $file")!=0) 128 141 { 129 142 &util::rm ($file);
Note:
See TracChangeset
for help on using the changeset viewer.