extras-buildsys/utils extras-repobuild.py, 1.2, 1.3 extras-sign-move.py, 1.2, 1.3
Seth Vidal (skvidal)
fedora-extras-commits at redhat.com
Wed Nov 2 14:21:11 UTC 2005
Author: skvidal
Update of /cvs/fedora/extras-buildsys/utils
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv32136
Modified Files:
extras-repobuild.py extras-sign-move.py
Log Message:
make extras-repobuild invoke repomanage to remove the older packages for any
given tree
Index: extras-repobuild.py
===================================================================
RCS file: /cvs/fedora/extras-buildsys/utils/extras-repobuild.py,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- extras-repobuild.py 19 Oct 2005 06:27:58 -0000 1.2
+++ extras-repobuild.py 2 Nov 2005 14:21:09 -0000 1.3
@@ -48,6 +48,8 @@
distdir = 'fedora-%s-extras' % dist
destdir = os.path.join(treedir, dist)
+
+ for arch in archdict[dist]
print "Making Repository Metadata"
# SRPM repo creation
repodir = os.path.join(destdir, 'SRPMS')
@@ -55,7 +57,13 @@
debugprint('removing tree %s' % rpdata)
if not DEBUG:
if os.path.exists(rpdata): shutil.rmtree(rpdata)
-
+
+ debugprint('Cleaning up older packages')
+ cmd = '/usr/bin/repomanage -k2 -o %s | xargs rm -f' % (repodir)
+ debugprint(cmd)
+ if not DEBUG:
+ result = os.system(cmd)
+
cmd = '/usr/bin/createrepo -c %s -q %s' % (cachedir, repodir)
debugprint(cmd)
if not DEBUG:
@@ -75,6 +83,12 @@
if not DEBUG:
if os.path.exists(rpdata): shutil.rmtree(rpdata)
+ debugprint('Cleaning up older packages')
+ cmd = '/usr/bin/repomanage -k2 -o %s | xargs rm -f' % (repodir)
+ debugprint(cmd)
+ if not DEBUG:
+ result = os.system(cmd)
+
if os.path.exists(compspath):
cmd = '/usr/bin/createrepo -c %s -q -g %s -x *debuginfo* %s' % (cachedir, compsname, repodir)
else:
@@ -94,6 +108,12 @@
if not DEBUG:
if os.path.exists(dbg_rpdata): shutil.rmtree(dbg_rpdata)
+ debugprint('Cleaning up older packages')
+ cmd = '/usr/bin/repomanage -k2 -o %s | xargs rm -f' % (repodir)
+ debugprint(cmd)
+ if not DEBUG:
+ result = os.system(cmd)
+
cmd = '/usr/bin/createrepo -c %s -q %s' % (cachedir, dbg_repodir)
debugprint(cmd)
if not DEBUG:
Index: extras-sign-move.py
===================================================================
RCS file: /cvs/fedora/extras-buildsys/utils/extras-sign-move.py,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- extras-sign-move.py 19 Oct 2005 06:27:58 -0000 1.2
+++ extras-sign-move.py 2 Nov 2005 14:21:09 -0000 1.3
@@ -125,7 +125,10 @@
s.connect()
s.sendmail(mail_from, [mail_to], msg.as_string())
s.close()
-
+
+
+
+
def sign_pkgs(filelist):
"""gpg sign all the rpms"""
numfiles = len(filelist)
@@ -162,6 +165,8 @@
print ' %s' % os.path.basename(item)
destdir = os.path.join(treedir, dist)
+ tmpdir = tempfile.mkdtemp(prefix=dist, dir='/var/tmp')
+
if not os.path.exists(destdir):
for arch in archdict[dist]:
if not DEBUG:
@@ -254,7 +259,7 @@
if not DEBUG:
os.unlink(file)
- # FIXME clean up empty dirs, too.
+
if __name__ == '__main__':
me = os.getcwd()
More information about the fedora-extras-commits
mailing list