From 5fafe9c962c2ac799c5d4a9684d962601d87035b Mon Sep 17 00:00:00 2001 From: Jesse Keating Date: Sep 14 2007 22:22:25 +0000 Subject: - Move the .composeinfo file into the directory we actually publish --- diff --git a/Changelog b/Changelog index 084f335..5a87321 100644 --- a/Changelog +++ b/Changelog @@ -1,5 +1,6 @@ * Fri Sep 14 2007 Jesse Keating - Create repoview content in the tree +- Move the .composeinfo file into the directory we actually publish * Wed Sep 12 2007 Jesse Keating - Remove python2.5 needs (Mark McLoughlin) diff --git a/pypungi/pungi.py b/pypungi/pungi.py index a8559b6..5a5f1ee 100755 --- a/pypungi/pungi.py +++ b/pypungi/pungi.py @@ -49,7 +49,8 @@ class Pungi(pypungi.PungiBase): self.common_files = [] self.infofile = os.path.join(self.config.get('default', 'destdir'), - '.composeinfo') + self.config.get('default', 'version'), + '.composeinfo') def writeinfo(self, line): """Append a line to the infofile in self.infofile""" @@ -60,11 +61,11 @@ class Pungi(pypungi.PungiBase): f.close() def mkrelative(self, subfile): - """Return the relative path for 'subfile' underneath 'self.destdir'.""" + """Return the relative path for 'subfile' underneath the version dir.""" - - if subfile.startswith(self.destdir): - return subfile.replace(self.destdir + os.path.sep, '') + basedir = os.path.join(self.destdir, self.config.get('default', 'version')) + if subfile.startswith(basedir): + return subfile.replace(basedir + os.path.sep, '') def doCreaterepo(self): """Run createrepo to generate repodata in the tree."""