Signed-off-by: Gui Chen <gui.chen@intel.com>
def __del__(self):
pass
+ def dirSetup(self):
+ super(MyYumRepository, self).dirSetup()
+ # relocate package dir
+ pkgdir = os.path.join(self.basecachedir, 'packages', self.id)
+ self.setAttribute('_dir_setup_pkgdir', pkgdir)
+ self._dirSetupMkdir_p(self.pkgdir)
+
def _getFile(self, url=None,
relative=None,
local=None,
cacheroot = repoinfo.packagesPath()
location= zypp.asKindPackage(po).location()
rpmpath = str(location.filename())
- pkgpath = "%s/%s" % (cacheroot, rpmpath)
+ pkgpath = "%s/%s" % (cacheroot, os.path.basename(rpmpath))
return pkgpath
def installLocal(self, pkg, po=None, updateonly=False):