history: Remove buildno-related stuff

This commit is contained in:
Fatih Aşıcı
2010-10-06 21:54:06 +00:00
parent 928ca84a9c
commit 4e3c38e0ab
2 changed files with 4 additions and 10 deletions
+2 -4
View File
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright (C) 2008, TUBITAK/UEKAE
# Copyright (C) 2008-2010, TUBITAK/UEKAE
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free
@@ -26,10 +26,9 @@ class PackageInfo:
a_version = [autoxml.String, autoxml.mandatory]
a_release = [autoxml.String, autoxml.mandatory]
a_build = [autoxml.String, autoxml.optional]
def __str__(self):
return self.version + "-" + self.release + "-" + (self.build or '?')
return self.version + "-" + self.release
class Repo:
a_operation = [autoxml.String, autoxml.mandatory]
@@ -137,7 +136,6 @@ class History(xmlfile.XmlFile):
if pkgInfo:
histInfo.version = str(pkgInfo.version)
histInfo.release = str(pkgInfo.release)
histInfo.build = pkgInfo.build and str(pkgInfo.build)
self.operation.packages.append(package)
+2 -6
View File
@@ -28,12 +28,8 @@ def __pkg_already_installed(name, pkginfo):
if not installdb.has_package(name):
return False
ver, rel, build = str(pkginfo).split("-")
if build == '?':
build = None
else:
build = int(build)
return (ver, rel, build) == installdb.get_version(name)
ver, rel = str(pkginfo).split("-")
return (ver, rel) == installdb.get_version(name)[:-1]
def __listactions(actions):