From ce89f3a03e5f76f3abdcc7512a18bf0f401cb3cb Mon Sep 17 00:00:00 2001 From: lxnay Date: Fri, 11 Apr 2008 01:17:06 +0000 Subject: [PATCH] create packages_dir if doesn't exist git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@1686 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- libraries/entropy.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libraries/entropy.py b/libraries/entropy.py index be91a7911..5febba31f 100644 --- a/libraries/entropy.py +++ b/libraries/entropy.py @@ -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)