fix. bug 613.
(arg... compared values are integer...)
This commit is contained in:
+7
-2
@@ -22,6 +22,7 @@
|
|||||||
|
|
||||||
|
|
||||||
import re
|
import re
|
||||||
|
import string
|
||||||
|
|
||||||
import pisi.util as util
|
import pisi.util as util
|
||||||
|
|
||||||
@@ -60,11 +61,15 @@ class VersionItem:
|
|||||||
self._keyword = keyword
|
self._keyword = keyword
|
||||||
|
|
||||||
if self._keyword == "NOKEY":
|
if self._keyword == "NOKEY":
|
||||||
self._value = itemstring
|
if len(itemstring) == 1 and itemstring in string.ascii_letters:
|
||||||
|
# single letter version item ('a' to 'Z')
|
||||||
|
self._value = itemstring
|
||||||
|
else:
|
||||||
|
self._value = int(itemstring)
|
||||||
else:
|
else:
|
||||||
# rest is the version item's value. And each must have
|
# rest is the version item's value. And each must have
|
||||||
# one!
|
# one!
|
||||||
self._value = itemstring[len(self._keyword):]
|
self._value = int(itemstring[len(self._keyword):])
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return str(self._value)
|
return str(self._value)
|
||||||
|
|||||||
Reference in New Issue
Block a user