[Debian-l10n-commits] r1662 - in /translate-toolkit/trunk/debian: changelog patches/series patches/storage_bzr

nekral-guest at users.alioth.debian.org nekral-guest at users.alioth.debian.org
Wed Mar 25 20:47:45 UTC 2009


Author: nekral-guest
Date: Wed Mar 25 20:47:44 2009
New Revision: 1662

URL: http://svn.debian.org/wsvn/?sc=1&rev=1662
Log:
  * debian/patches/storage_bzr: Added patch to execute bzr from the pootle's
    working copy. Thanks to Roland Mas.

Added:
    translate-toolkit/trunk/debian/patches/storage_bzr
Modified:
    translate-toolkit/trunk/debian/changelog
    translate-toolkit/trunk/debian/patches/series

Modified: translate-toolkit/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/translate-toolkit/trunk/debian/changelog?rev=1662&op=diff
==============================================================================
--- translate-toolkit/trunk/debian/changelog (original)
+++ translate-toolkit/trunk/debian/changelog Wed Mar 25 20:47:44 2009
@@ -1,3 +1,10 @@
+translate-toolkit (1.3.0-4) unstable; urgency=low
+
+  * debian/patches/storage_bzr: Added patch to execute bzr from the pootle's
+    working copy. Thanks to Roland Mas.
+
+ -- Nicolas FRANCOIS (Nekral) <nicolas.francois at centraliens.net>  Wed, 25 Mar 2009 21:41:44 +0100
+
 translate-toolkit (1.3.0-3) unstable; urgency=low
 
   * debian/control: Recommend python-levenshtein. Otherwise, the toolkit

Modified: translate-toolkit/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/translate-toolkit/trunk/debian/patches/series?rev=1662&op=diff
==============================================================================
--- translate-toolkit/trunk/debian/patches/series (original)
+++ translate-toolkit/trunk/debian/patches/series Wed Mar 25 20:47:44 2009
@@ -2,3 +2,4 @@
 tools_manpages
 API-doc-in-separate-package
 test_optrecurse-typo
+storage_bzr

Added: translate-toolkit/trunk/debian/patches/storage_bzr
URL: http://svn.debian.org/wsvn/translate-toolkit/trunk/debian/patches/storage_bzr?rev=1662&op=file
==============================================================================
--- translate-toolkit/trunk/debian/patches/storage_bzr (added)
+++ translate-toolkit/trunk/debian/patches/storage_bzr Wed Mar 25 20:47:44 2009
@@ -1,0 +1,67 @@
+Goal: Do not require pootle to be run from the root directory. Useful to
+refresh the stats
+
+Thanks to Roland Mas.
+
+Should be forwarded upstream.
+
+--- a/translate/storage/versioncontrol/bzr.py
++++ b/translate/storage/versioncontrol/bzr.py
+@@ -55,17 +55,17 @@
+     def update(self, revision=None):
+         """Does a clean update of the given path"""
+         # bzr revert
+-        command = ["bzr", "revert", self.location_abs]
+-        exitcode, output_revert, error = run_command(command)
++        command = ["bzr", "revert", self.location_rel]
++        exitcode, output_revert, error = run_command(command, self.root_dir)
+         if exitcode != 0:
+             raise IOError("[BZR] revert of '%s' failed: %s" \
+-                    % (self.location_abs, error))
++                    % (self.location_rel, error))
+         # bzr pull
+         command = ["bzr", "pull"]
+-        exitcode, output_pull, error = run_command(command)
++        exitcode, output_pull, error = run_command(command, self.root_dir)
+         if exitcode != 0:
+             raise IOError("[BZR] pull of '%s' failed: %s" \
+-                    % (self.location_abs, error))
++                    % (self.root_dir, error))
+         return output_revert + output_pull
+ 
+     def commit(self, message=None, author=None):
+@@ -78,26 +78,26 @@
+         if author and (get_version() >= (0, 91)):
+             command.extend(["--author", author])
+         # the filename is the last argument
+-        command.append(self.location_abs)
+-        exitcode, output_commit, error = run_command(command)
++        command.append(self.location_rel)
++        exitcode, output_commit, error = run_command(command, self.root_dir)
+         if exitcode != 0:
+             raise IOError("[BZR] commit of '%s' failed: %s" \
+-                    % (self.location_abs, error))
++                    % (self.location_rel, error))
+         # bzr push
+         command = ["bzr", "push"]
+-        exitcode, output_push, error = run_command(command)
++        exitcode, output_push, error = run_command(command, self.root_dir)
+         if exitcode != 0:
+             raise IOError("[BZR] push of '%s' failed: %s" \
+-                    % (self.location_abs, error))
++                    % (self.root_dir, error))
+         return output_commit + output_push
+ 
+     def getcleanfile(self, revision=None):
+         """Get a clean version of a file from the bzr repository"""
+         # bzr cat
+-        command = ["bzr", "cat", self.location_abs]
+-        exitcode, output, error = run_command(command)
++        command = ["bzr", "cat", self.location_rel]
++        exitcode, output, error = run_command(command, self.root_dir)
+         if exitcode != 0:
+             raise IOError("[BZR] cat failed for '%s': %s" \
+-                    % (self.location_abs, error))
++                    % (self.location_rel, error))
+         return output
+ 




More information about the Debian-l10n-commits mailing list