From: Brion Vibber Date: Sun, 16 Oct 2005 23:34:20 +0000 (+0000) Subject: Support using gzip and bzip2 decompression wrappers on the prefetch XML X-Git-Tag: 1.6.0~1403 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22articles%22%2C%22id_article=%24id_article%22%29%20.%20%22?a=commitdiff_plain;h=b393b81d97f44d51997891fa17aadca2dc0cfcf0;p=lhc%2Fweb%2Fwiklou.git Support using gzip and bzip2 decompression wrappers on the prefetch XML source (--prefix=bzip2:foo.xml.bz2) --- diff --git a/maintenance/dumpTextPass.php b/maintenance/dumpTextPass.php index bb1b194b32..ae55ec8f88 100644 --- a/maintenance/dumpTextPass.php +++ b/maintenance/dumpTextPass.php @@ -62,7 +62,20 @@ class TextPassDumper extends BackupDumper { function processOption( $opt, $val, $param ) { if( $opt == 'prefetch' ) { require_once 'maintenance/backupPrefetch.inc'; - $this->prefetch = new BaseDump( $val ); + switch( $val ) { + case "file": + $filename = $param; + break; + case "gzip": + $filename = "compress.gzip://$param"; + break; + case "bzip2": + $filename = "compress.bzip2://$param"; + break; + default: + $filename = $val; + } + $this->prefetch = new BaseDump( $filename ); } }