[yum-commits] 2 commits - plugins/tmprepo repoquery.py

zpavlas at osuosl.org zpavlas at osuosl.org
Mon Jun 3 16:15:54 UTC 2013


 plugins/tmprepo/tmprepo.py |    2 +-
 repoquery.py               |    6 ++++++
 2 files changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 9e70c28fb9e55b41a3cc4130f1c618f8d98fb33e
Author: Zdenek Pavlas <zpavlas at redhat.com>
Date:   Mon Jun 3 09:41:28 2013 +0200

    repoquery: add cachedir locking. BZ 969776

diff --git a/repoquery.py b/repoquery.py
index 303ee3e..403074b 100755
--- a/repoquery.py
+++ b/repoquery.py
@@ -1499,6 +1499,12 @@ def main(args):
                 repo.enable()
 
     try:
+        repoq.doLock()
+    except yum.Errors.LockError, e:
+        repoq.logger.error(e)
+        sys.exit(50)
+
+    try:
         if not hasattr(repoq, 'arch'):
             repoq.doSackSetup(archlist=archlist)
         elif archlist is not None:
commit f70833f54128a9356a42abada0d86d98e299882a
Author: Sergio Monteiro Basto <sergio at serjux.com>
Date:   Mon May 27 15:43:05 2013 +0200

    tmprepo: avoid spaces in repoid. BZ 965806
    
    Signed-off-by: Zdenek Pavlas <zpavlas at redhat.com>

diff --git a/plugins/tmprepo/tmprepo.py b/plugins/tmprepo/tmprepo.py
index e60dd4d..93e560a 100644
--- a/plugins/tmprepo/tmprepo.py
+++ b/plugins/tmprepo/tmprepo.py
@@ -133,7 +133,7 @@ def add_repomd_repo(base, repomd):
     AutoCleanupDir(trepo_data)
     trepo_name = os.path.basename(os.path.dirname(os.path.dirname(repomd)))
     tmp_fname  = "%s/tmp-%s.repo" % (trepo_data, trepo_name)
-    repoid     = "T-%4.4s-%x" % (trepo_name, int(time.time()))
+    repoid     = "T-%0.4s-%x" % (trepo_name, int(time.time()))
     pgpgcheck, rgpgcheck = rpgpgcheck, rrgpgcheck
     if repomd.startswith("file:"):
         pgpgcheck, rgpgcheck = lpgpgcheck, lrgpgcheck


More information about the Yum-commits mailing list