From ef11fef7ecdd0c6cef14fbbf245b2ce93c523bc1 Mon Sep 17 00:00:00 2001 From: Zhang Qiang Date: Wed, 4 Jan 2012 16:03:45 +0800 Subject: [PATCH] Check existance of local packages dir --- mic/creator.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mic/creator.py b/mic/creator.py index a55132e..5b28deb 100644 --- a/mic/creator.py +++ b/mic/creator.py @@ -156,6 +156,9 @@ class Creator(cmdln.Cmdln): configmgr.create['cachedir'] = self.options.cachedir os.environ['ZYPP_LOCKFILE_ROOT'] = configmgr.create['cachedir'] if self.options.local_pkgs_path is not None: + if not os.path.exists(self.options.local_pkgs_path): + msger.error('Local pkgs directory: \'%s\' not exist' \ + % self.options.local_pkgs_path) configmgr.create['local_pkgs_path'] = self.options.local_pkgs_path if self.options.release: -- 2.7.4