[Python-modules-commits] r26361 - in packages/python-git/trunk/debian (4 files)

bernat at users.alioth.debian.org bernat at users.alioth.debian.org
Sat Nov 2 00:45:31 UTC 2013


    Date: Saturday, November 2, 2013 @ 00:45:28
  Author: bernat
Revision: 26361

Correctly parses `git --version`. Closes: #722481.

Added:
  packages/python-git/trunk/debian/patches/
  packages/python-git/trunk/debian/patches/dont-choke-on-rc-version.patch
  packages/python-git/trunk/debian/patches/series
Modified:
  packages/python-git/trunk/debian/changelog

Modified: packages/python-git/trunk/debian/changelog
===================================================================
--- packages/python-git/trunk/debian/changelog	2013-11-02 00:35:50 UTC (rev 26360)
+++ packages/python-git/trunk/debian/changelog	2013-11-02 00:45:28 UTC (rev 26361)
@@ -2,6 +2,8 @@
 
   * Update Homepage to a working URL.
   * Bump Standards-Version to 3.9.5.
+  * Correctly parses `git --version` when not all components are
+    numeric. Closes: #722481.
 
  -- Vincent Bernat <bernat at debian.org>  Sat, 02 Nov 2013 01:27:18 +0100
 

Added: packages/python-git/trunk/debian/patches/dont-choke-on-rc-version.patch
===================================================================
--- packages/python-git/trunk/debian/patches/dont-choke-on-rc-version.patch	                        (rev 0)
+++ packages/python-git/trunk/debian/patches/dont-choke-on-rc-version.patch	2013-11-02 00:45:28 UTC (rev 26361)
@@ -0,0 +1,22 @@
+Author: "Marcus R. Brown" <mrbrown at precision-mojo.com>
+Description: Fix the `git version` parser to not choke on stuff like
+  '1.8.4.rc3'.
+Origin: https://github.com/gitpython-developers/GitPython/pull/88
+Bug-Debian: http://bugs.debian.org/722481
+
+diff --git a/git/cmd.py b/git/cmd.py
+index 576a530..6bd7901 100644
+--- a/git/cmd.py
++++ b/git/cmd.py
+@@ -234,7 +234,7 @@ def _set_cache_(self, attr):
+ 		if attr == '_version_info':
+ 			# We only use the first 4 numbers, as everthing else could be strings in fact (on windows)
+ 			version_numbers = self._call_process('version').split(' ')[2]
+-			self._version_info = tuple(int(n) for n in version_numbers.split('.')[:4])
++			self._version_info = tuple(int(n) for n in version_numbers.split('.')[:4] if n.isdigit())
+ 		else:
+ 			super(Git, self)._set_cache_(attr)
+ 		#END handle version info
+-- 
+1.8.4
+

Added: packages/python-git/trunk/debian/patches/series
===================================================================
--- packages/python-git/trunk/debian/patches/series	                        (rev 0)
+++ packages/python-git/trunk/debian/patches/series	2013-11-02 00:45:28 UTC (rev 26361)
@@ -0,0 +1 @@
+dont-choke-on-rc-version.patch




More information about the Python-modules-commits mailing list