remove the old package if exists, remove the debug message
authorHasan Wan <hasan.wan@intel.com>
Fri, 31 May 2013 08:44:50 +0000 (16:44 +0800)
committerHasan Wan <hasan.wan@intel.com>
Wed, 5 Jun 2013 03:02:48 +0000 (11:02 +0800)
Change-Id: If18611e8398ec105c63d2f2cf993bb5f290ac2ba
Signed-off-by: Hasan Wan <hasan.wan@intel.com>
common/buildservice.py
common/repomaker.py

index 92a6363..8333c0d 100644 (file)
@@ -321,7 +321,6 @@ class BuildService(OSC):
     def get_repo_state(self, project):
         """Get repo's state of the project"""
         targets = {}
-        print "==%s= %s=" % self.apiurl, project
         try:
             tree = ElementTree.fromstring(''.join(core.show_prj_results_meta( \
                     self.apiurl, project)))
index a34638a..4d60b0e 100644 (file)
@@ -90,6 +90,8 @@ def move_or_hardlink(fpath, target_dirs, move=False):
                 # already moved noarch package. symlink it.
                 os.symlink(os.path.join(target_dirs[0], fname), tpath)
         else:
+            if os.path.isfile(tpath):
+                os.remove(tpath)
             os.link(fpath, tpath)
 
 class RepoMaker(object):