rename_failed = Could not move/rename '{FILE}' to '{NEW_FILE}'.
rename_root = You are not allowed to move/rename the root directory.
text_to_binary = You are not allowed to write text data into a binary file.
-unpack_failed = Unpacking of archive file '{FILE}' failed.
+unpack_failed = Unpacking of archive file '{FILE}' failed.<br><br><tt>Archive::Extract</tt> returned the following error:<br><tt>{AE_ERROR}</tt>
unpack_no_dir = You cannot unpack archive file '{FILE}' to an ordinary file or a symbolic ('{NEW_FILE}' is not a directory).
# End of configuration file
\ No newline at end of file
# Execute Dev-Editor's commands
#
# Author: Patrick Canterino <patrick@patshaping.de>
-# Last modified: 2010-12-31
+# Last modified: 2011-01-05
#
# Copyright (C) 1999-2000 Roland Bluethgen, Frank Schoenmann
# Copyright (C) 2003-2009 Patrick Canterino
my $return_unpack = archive_unpack($physical,$new_physical);
- return error($config->{'errors'}->{'unpack_failed'},$dir,{FILE => encode_html($virtual), AE_ERROR => ''}) unless($return_unpack);
+ return error($config->{'errors'}->{'unpack_failed'},$dir,{FILE => encode_html($virtual), AE_ERROR => encode_html($File::Access::archive_extract_error)}) unless($return_unpack);
return devedit_reload({command => 'show', file => $new_virtual});
}
# using only one command
#
# Author: Patrick Canterino <patrick@patshaping.de>
-# Last modified: 2010-12-27
+# Last modified: 2011-01-05
#
# Copyright (C) 1999-2000 Roland Bluethgen, Frank Schoenmann
# Copyright (C) 2003-2009 Patrick Canterino
use vars qw(@EXPORT
$has_flock
- $has_archive_extract);
+ $has_archive_extract
+ $archive_extract_error);
use Fcntl qw(:DEFAULT
:flock);
if($path)
{
- return $ae->extract(to => $path);
+ if($ae->extract(to => $path))
+ {
+ return 1;
+ }
+ else
+ {
+ $archive_extract_error = $ae->error;
+ return;
+ }
}
else
{
- return $ae->extract;
+ if($ae->extract)
+ {
+ return 1;
+ }
+ else
+ {
+ $archive_extract_error = $ae->error;
+ return;
+ }
}
}
# Some shared sub routines
#
# Author: Patrick Canterino <patrick@patshaping.de>
-# Last modified: 2010-12-23
+# Last modified: 2011-01-05
#
# Copyright (C) 1999-2000 Roland Bluethgen, Frank Schoenmann
# Copyright (C) 2003-2009 Patrick Canterino
multi_string
upper_path);
-my @archive_exts = ('.zip', 'tar.gz', 'tar.bz2');
+my @archive_exts = ('.zip', '.tar', '.gz',
+ '.tar.gz', '.tgz', '.bz2',
+ '.tar.bz2', '.tbz', '.tbz2',
+ '.Z');
# check_path()
#