create packages_dir if doesn't exist

git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@1686 cd1c1023-2f26-0410-ae45-c471fc1f0318
This commit is contained in:
lxnay
2008-04-11 01:17:06 +00:00
parent 054ff3d43d
commit ce89f3a03e
+3
View File
@@ -14167,6 +14167,9 @@ class ServerMirrorsInterface:
local_packages = set()
packages_dir = os.path.join(self.Entropy.get_local_packages_directory(repo),branch)
if not os.path.isdir(packages_dir):
os.makedirs(packages_dir)
for package in os.listdir(packages_dir):
if package.endswith(etpConst['packagesext']) or package.endswith(etpConst['packageshashfileext']):
local_packages.add(package)