r33005 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r33004‎ | r33005 | r33006 >
Date:01:35, 9 April 2008
Author:brion
Status:old
Tags:
Comment:
Tell dumpTextPass to use dbzip2 only if we've been configured for it; otherwise use regular bzip2
Modified paths:
  • /trunk/backup/worker.py (modified) (history)

Diff [purge]

Index: trunk/backup/worker.py
@@ -691,7 +691,11 @@
692692 def buildFilters(self, runner):
693693 """Construct the output filter options for dumpTextPass.php"""
694694 xmlbz2 = self._path(runner, "bz2")
695 - return "--output=dbzip2:%s" % shellEscape(xmlbz2)
 695+ if runner.config.bzip2[-6:] == "dbzip2":
 696+ bz2mode = "dbzip2"
 697+ else:
 698+ bz2mode = "bzip2"
 699+ return "--output=%s:%s" % shellEscape(bz2mode, xmlbz2)
696700
697701 def buildCommand(self, runner):
698702 """Build the command line for the dump, minus output and filter options"""

Status & tagging log