Moodle Plugins directory: External zip utility | Moodle.org
External zip utility
Other tools ::: local_externalzip
Maintained by
Aaron Wells
Allows Moodle to use the command-line zip utility (/usr/bin/zip) instead of the PHP ZipArchive library.
Latest release:
17 sites
7 downloads
2 fans
Current versions available: 1
This package adds a settings page to allow Moodle to use external command-line zip and unzip utilities rather than the PHP ZipArchive library. It's intended as a workaround to ZipArchive's inability to handle large zip files (see http://tracker.moodle.org/browse/MDL-34388 ).
I've only tested it in Ubuntu 12.04, so it may not work properly on other platforms, if their "zip" and "unzip" utilities have different command-line options or output formats. It almost certainly won't work in Windows, although it could with some work.
I welcome community contributions. If you've got a fix to make this plugin work on a different OS, or with a later version of Moodle, please send me a github pull request or a patch file.
Useful links
Contributors
Aaron Wells (Lead maintainer)
Please login to view contributors details and/or to contact them
This seems a worthy addition to many Moodle sites, but I could not find the language strings available for translating it to other languages in AMOS. This could be due to the language strings not properly managed (but they are indeed in the local_externalzip.php file).
Below are the mexican spanish translated strings:
<?php
$string['pluginname'] = 'Utilería ZIP externa';
$string['ziphandler'] = 'Manejador de archivo ZIP';
$string['ziphandler_help'] = "Moodle soporta completamente tanto usar la biblioteca PHP ZipArchive o usar una utilería ZIP externa. ZipArchive es soportada completamente por Moodle, pero se sabe que tiene problemas al manejar archivos mayores de 2GB.";
$string['phpziparchive_option'] = 'ZipArchive';
$string['externalzip_option'] = 'Utilería ZIP externa';
$string['pathtozip'] = 'Ruta a zip';
$string['pathtozip_help'] = 'Ruta a utilería ZIP externa';
$string['pathtounzip'] = 'Ruta a UNZIP';
$string['pathtounzip_help'] = 'Ruta a utilería UNZIP externa';
Would you be so kind as to check this. Help may be available by David Mudrak (in charge of language tool)
Thanks,
German Valero (mexican spanish language pack maintainer).
Thanks for creating this plugin. I was able to install the plugin. I turned on External Zip Utility. Made sure the paths were correct. However, we're still not able to restore a course from a file over 2GB. Course under 2GB are okay. We're still getting the "error/tmp_backup_directory_not_found" error. Any ideas what might be causing this? Thanks. John
patch -p1 < local/externalzip/lib-filestorage-zip_archive-php.patch
in fact, you need to run:
patch -p1 < local/externalzip/lib-filestorage-zip_archive.php.patch
(it's archive.php, not archive-php). Once I did that from the command line, it all worked!
So, John might be having the same problem as I was which is that, while it LOOKED like the external zip add-on was installed and selected to be used instead of ZipArchive, it was still trying to use ZipArchive.
Sorry for the slow reply. I think the reason my strings don't show up in AMOS is because this plugin is classified as an "Other" plugin, and therefore AMOS doesn't know where its strings should go. I submitted it as a "Local" plugin, but the Moodle plugin directory maintainers decided it should be an "Other" because it includes a patch file.
Fortunately, the only changes it makes to the interface are on the admin screens, so end users won't see untranslated English strings. I'll go ahead and include your Mexican Spanish translation in the package as well.
By the way, you'll appreciate that, due to the time zone difference, my Mac is reporting the new files as modified on "Tomorrow 10:34 AM".
I've put together a new revision with upgrade instructions, version 0.9.2.
I'm not sure, though, if installation of the plugin via Moodle works now (it didn't run the patch when I did it that way with version 0.9.0), but manual installation works.
Correct me if I'm wrong, but it seems like the README.txt file included with version 0.9.2 does not include the upgrade instructions; I had to find those on this page in the Downloads tab, under "See more".
I had tested the plugin in Moodle 2.5.1+ (Build: 20130808) at ubuntu13.04, and follow the instruction in readme.txt ,but failed to install,could you help me?Thank you very much
if ($pathinarchive == '') {
return true;
}
makes it work for us.